in reply to Re^3: Renaming an image file
in thread Renaming an image file

You are of course right regarding the collisons.

What I meant was that when using filenames rather then content for hashing, you avoid the case that you have 2 files with the same content, thus resulting in a (trivial) collision that can be avoided by hashing the name.

Replies are listed 'Best First'.
Re^5: Renaming an image file
by Anonymous Monk on Nov 28, 2010 at 08:55 UTC
    If you have 2 files with the same content and you've detected them, then you've saved some space
      Until you want to delete one of them and keep the other. Unless you change your archival system so that it can deal with shared images, it'll be ill advised to silently have them point to the same physical structure.
        fore sure, but if that is the case, why store it in the same directory? or why rename the file at all?