-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
need to close Reader after parsing is finished #13
Comments
There is a Did you mean elsewhere? |
Ah, yes, but that version of the code is not what you get when you BTW, is there some reason you've excluded your 'build' directory from the repo? I've forked to fix another issue and I've been just editing the big concatenated 'dist/id3.js' file directly, but I assume that's not how you do it. I meant to contact you about this before sending a pull request, but I hadn't gotten around to it. |
Sorry about that, its a bit of a mess. Being that it began as a much smaller lib, I initially didn't have a solid build process. Then parts of it got forked off to other repos (dataview, reader.js) and now its a bit of a mess and a pain to update. Really, they should be deps now but we can't just You can edit |
id3() creates a new Reader and calls its .open method but never closes it. If you don't cycle through lots of files quickly, this does not seem to be a problem (presumably because the Reader eventually gets destroyed and the file handle along with it), but if you churn through a lot of files very quickly, this can cause you to run out of file handles and id3 eventually starts failing with "Could not open specified file." The fix is simply to put a call to handle.close() inside the ID3Tag.parse callback.
The text was updated successfully, but these errors were encountered: