Hello,

I'm working with a printer device and overhauling some node.js code. 
Previously, communication was done with set interval reads, with writes in 
between.
I thought that it could be a good idea to implement a native C polling 
interface using node-gyp to compile a node.js-compatible addon.
However, I'm having run-time issues : SEGFAULT.

The SEGFAULT happens every time there is a Garbage Collection sweep. 
Starting node.js with the --expose-gc option and calling `global.gc()' 
causes an immediate crash.
Since the software turns on a low-capacity/low-power embedded Linux, and we 
don't have any debug symbols for node.js, I tried replicating it on my 
system, but I have 0 issue here.
The garbage collection is done, and the program continues to work as 
intended.

So... I'm kinda lost, and don't know what I'm doing wrong. My code is 
heavily inspired by the node's serialport module (also using libuv and the 
uv_poll methods).

You can find a full snippet of my program here : 
https://gist.github.com/Neph0/511fbd967300e231e91d5a9052c329b8

Any help would be greatly appreciated, I'm stuck on this.

-- 
Thomas

-- 
Job board: http://jobs.nodejs.org/
New group rules: 
https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/nodejs/76140842-9487-4d2f-9dde-dac0811ff510%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to