Author pitrou
Recipients exarkun, giampaolo.rodola, janssen, loewis, pitrou
Date 2010-06-19.22:14:12
SpamBayes Score 0.00253351
Marked as misclassified No
Message-id <1276985655.04.0.643445903194.issue8524@psf.upfronthosting.co.za>
In-reply-to
Content
I have tried refactoring the ssl code in order not to inherit from socket anymore, but it turned out suboptimal because chunks of code from the socket class then have to be duplicated.

Therefore, I instead propose a much simpler approach which is to add a forget() method to socket objects; this method "closes" the socket object (sets the internal fd to -1) without closing the underlying fd at all. This allows to create another socket (actually SSLSocket) from the same fd without having to dup() it.

Here is a patch; if the principle is accepted, I will add tests and docs.
History
Date User Action Args
2010-06-19 22:14:15pitrousetrecipients: + pitrou, loewis, exarkun, janssen, giampaolo.rodola
2010-06-19 22:14:15pitrousetmessageid: <1276985655.04.0.643445903194.issue8524@psf.upfronthosting.co.za>
2010-06-19 22:14:13pitroulinkissue8524 messages
2010-06-19 22:14:13pitroucreate