Skip to content
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

Segmentation Fault #44

Open
guicontat opened this issue Jul 20, 2015 · 0 comments
Open

Segmentation Fault #44

guicontat opened this issue Jul 20, 2015 · 0 comments

Comments

@guicontat
Copy link

Hello,

My code :

var coreAudio = require("node-core-audio")
, SegfaultHandler = require('segfault-handler')
;

SegfaultHandler.registerHandler();
var engine = coreAudio.createNewAudioEngine();

function processAudio( inputBuffer ) {
return inputBuffer[0][0];
}

engine.addAudioCallback( processAudio );

does a Segmentation Fault.

Here is the stacktrace

PID 7906 received SIGSEGV for address: 0x20
/home/guicontat/live_sound/node_modules/segfault-handler/build/Release/segfault-handler.node(+0x1175)[0x7fe452383175]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x10340)[0x7fe453564340]
/home/guicontat/live_sound/node_modules/node-core-audio/build/Release/NodeCoreAudio.node(_ZN5Audio11AudioEngine12applyOptionsEN2v85LocalINS1_6ObjectEEE+0x1de)[0x7fe45017a6ee]
/home/guicontat/live_sound/node_modules/node-core-audio/build/Release/NodeCoreAudio.node(_ZN5Audio11AudioEngineC1EN2v85LocalINS1_6ObjectEEE+0x1c5)[0x7fe45017ad95]
/home/guicontat/live_sound/node_modules/node-core-audio/build/Release/NodeCoreAudio.node(_ZN5Audio11AudioEngine3NewERKN2v820FunctionCallbackInfoINS1_5ValueEEE+0x71)[0x7fe45017b141]
node(_ZN2v88internal25FunctionCallbackArguments4CallEPFvRKNS_20FunctionCallbackInfoINS_5ValueEEEE+0x92)[0x7b8e02]
node[0x7d87d0]
[0x28af33d0740e]

aplay -l return

**** Liste des Périphériques Matériels PLAYBACK ****
carte 0: Intel [HDA Intel], périphérique 0: AD1984A Analog [AD1984A Analog]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0
carte 0: Intel [HDA Intel], périphérique 2: AD1984A Alt Analog [AD1984A Alt Analog]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0
carte 1: NVidia [HDA NVidia], périphérique 3: HDMI 0 [HDMI 0]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0
carte 1: NVidia [HDA NVidia], périphérique 7: HDMI 0 [HDMI 0]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0
carte 1: NVidia [HDA NVidia], périphérique 8: HDMI 0 [HDMI 0]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0
carte 1: NVidia [HDA NVidia], périphérique 9: HDMI 0 [HDMI 0]
Sous-périphériques: 1/1
Sous-périphérique #0: subdevice #0

The Segfault is cause by

line 214 in AudioEngine.cpp

m_inputParams.suggestedLatency = Pa_GetDeviceInfo(m_inputParams.device)->defaultLowInputLatency;

and line 220

m_outputParams.suggestedLatency = Pa_GetDeviceInfo(m_outputParams.device)->defaultLowOutputLatency;
Do you know how can i fix it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant