Am Donnerstag, den 08.03.2007, 01:30 -0300 schrieb Sidnei da Silva: > On 3/7/07, Christian Theune <[EMAIL PROTECTED]> wrote: > > I propose to create a small subclass to override the `make_file` method > > to use `NamedTemporaryFile` instead of `TemporaryFile` to allow the file > > being accessible from a filename so I can apply a `link` operation. > > > > Notice: The FieldStorage explicitly provides the `make_file` method to > > allow overriding in this sense. > > Since you're proposing to replace TemporaryFile anyway, and your > 'os.link()' proposal requires that both the file and the hard link are > on the same 'drive' or 'partition' or whatever, why not create the > temporary file on a temp directory that is close (hopefully a sibling) > of the final destination blob directory, then you can be sure that > 'os.link()' will work and will be 'O(1)' without any extra effort. > > Is there any reason not to do that?
Admin-Choice. You can already configure this directory to be on the same destination by setting your tempdir environment accordingly. -- gocept gmbh & co. kg - forsterstraße 29 - 06112 halle/saale - germany www.gocept.com - [EMAIL PROTECTED] - phone +49 345 122 9889 7 - fax +49 345 122 9889 1 - zope and plone consulting and development
signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil
_______________________________________________ Zope3-dev mailing list [email protected] Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
