Best practice for variables shared between processes?

David Cantrell david at cantrell.org.uk
Tue Sep 21 13:53:33 BST 2010


On Tue, Sep 21, 2010 at 09:13:19AM +1000, Daniel Pittman wrote:

> Just make sure it is a move, not a copy, of the file; at least one developer
> around me has dropped in File::Copy::move when they got a plain rename refused
> because it crossed devices ??? so ended up copying the data in anyway.

stat both directories, check the device number. If they differ, do
something clever, like creating a temp dir in the destination, copying
to that, and then moving to the parent.

-- 
David Cantrell | Hero of the Information Age

  On the bright side, if sendmail is tied up routing spam and pointless
  uknot posts, it's not waving its arse around saying "root me!"
      -- Peter Corlett, in uknot


More information about the london.pm mailing list