andrewrk / node-groove

bindings to libgroove - music player backend library
MIT License
157 stars 16 forks source link

mysterious crash when opening file #9

Closed whmountains closed 9 years ago

whmountains commented 9 years ago

The code that i've published to this gist causes my app to exit with the following error message:

Assertion failed: (handle->InternalFieldCount() > 0), function Unwrap, file /Users/mmc/.node-gyp/0.10.31/src/node_object_wrap.h, line 61.
Abort trap: 6

To test it just run DEBUG=* node groovetester.js path/to/audio.file with groove.js and groovetester.js in the same directory. If you set a breakpoint at line 30 of groove.js, execution reaches that line and then exits while execution is paused.

I suspect that this is a bug with node-groove or libgroove because of the mysterious crash when execution is paused, but I will continue to look for bugs in my own code that might cause it. Even if it were my fault, however, it would be nice if node-groove could be patched to set the error argument of the callback function to true rather than just crashing.

Thanks again for making libgroove and node-groove :)

andrewrk commented 9 years ago

Your code is doing a lot of convoluted stuff. When I deleted it and left only the commands to the groove module, everything worked fine. I think there is a bug in your program.

Here's an example of using the fingerprinter: https://github.com/andrewrk/node-groove/blob/master/example/fingerprint.js

I recommend starting with the simple example (which works) and working your way up to your more complicated code.

whmountains commented 9 years ago

OK, I'll take that as a lesson that I'm going too fast for my ability. Sorry to waste your time.

On Nov 15, 2014, at 6:03 PM, Andrew Kelley notifications@github.com wrote:

Your code is doing a lot of convoluted stuff. When I deleted it and left only the commands to the groove module, everything worked fine. I think there is a bug in your program.

Here's an example of using the fingerprinter: https://github.com/andrewrk/node-groove/blob/master/example/fingerprint.js

I recommend starting with the simple example (which works) and working your way up to your more complicated code.

— Reply to this email directly or view it on GitHub.

andrewrk commented 9 years ago

I don't think my time was wasted. Please feel free to report any other issues you have, and feel free to join the chat room and ask for help or advice.