kripken/emscripten — pull request #1519 by rfk (2013-08-15 03:02:46+00:00)
Title: Ensure FS.hashName returns a positive integer

The FS.hashName() function can sometimes return negative numbers, which causes subsequent lookups to fail and produce ENOENT for files that are supposed to exist.

Since this is a pre-allocated array I'm assuming you want all the hashes to be positive integers. This PR fixes the issue for me, but maybe there is a better way to do it by changing the hash function itself.