in reply to Re^3: Unique filenames with Time::HiRes
in thread Unique filenames with Time::HiRes
Maybe just append a random number
Or maybe not.
The OP states that the names must be in sequence. Consider two files created in the epoch second 1090225457. The first file is generated with the rand string 0.837 (rounded). Half a second later, still in the same epoch second, another file is created, and rand returns 0.238 (rounded). The second file will sort before the first...
The same critism can be made of beable's solution elsewhere in this thread.
- another intruder with the mooring of the heat of the Perl
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Unique filenames with Time::HiRes
by bsb (Priest) on Jul 21, 2004 at 01:33 UTC | |
|
Re^5: Unique filenames with Time::HiRes
by beable (Friar) on Jul 19, 2004 at 08:32 UTC | |
by DrHyde (Prior) on Jul 20, 2004 at 08:09 UTC |