Closed laowangnj closed 6 years ago
would it be possible for you to share the code to reproduce the crash?
Also, please if you can pleas recompile in debug to get a cleaner trace:
on binding.gyp
change
"cflags":
[
"-fexceptions",
"-std=c++11",
"-O3",
#"-g",
#"-O0",
#"-fsanitize=address"
],
by
"cflags":
[
"-fexceptions",
"-std=c++11",
#"-O3",
"-g",
"-O0",
"-fsanitize=address"
],
and recompile with npm run-script build
module.js:681 return process.dlopen(module, path._makeLong(filename)); ^
Error: /home/wang/workspace/media-server-remote/node_modules/medooze-media-server/build/Release/medooze-media-server.node: undefined symbol: __asan_option_detect_stack_use_after_return
at Object.Module._extensions..node (module.js:681:18)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object.
and firefox joined to supply init stream。
------------------ Original ------------------ From: "Sergio Garcia Murillo"notifications@github.com; Date: Mon, Apr 16, 2018 05:30 PM To: "medooze/media-server-demo-node"media-server-demo-node@noreply.github.com; Cc: "J"njwxc@qq.com; "Author"author@noreply.github.com; Subject: Re: [medooze/media-server-demo-node] node crashed (#9)
would it be possible for you to share the code to reproduce the crash?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
comment out the "-fsanitize=address"
option sorry
stack_end=0x7ffd80bb22e8) at ../csu/libc-start.c:291
------------------ Original ------------------ From: "Sergio Garcia Murillo"notifications@github.com; Date: Mon, Apr 16, 2018 06:15 PM To: "medooze/media-server-demo-node"media-server-demo-node@noreply.github.com; Cc: "J"njwxc@qq.com; "Author"author@noreply.github.com; Subject: Re: [medooze/media-server-demo-node] node crashed (#9)
comment out the "-fsanitize=address" option sorry
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Please, check the latest version to see if it solves the problem (and open the issue again if not)
Thank you!
v0.26.5 stay the same. v0.27.x runs error
please check latest v.0.29.1
v0.29.1 Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". Core was generated by `node index.js'. Program terminated with signal SIGSEGV, Segmentation fault.
4169 malloc.c: No such file or directory. [Current thread is 1 (Thread 0x7fc9ceff5700 (LWP 21541))] (gdb) bt
this=<synthetic pointer>) at /usr/include/c++/5/bits/shared_ptr_base.h:1125
at /usr/include/c++/5/bits/shared_ptr.h:319
at /usr/include/c++/5/bits/shared_ptr.h:636
I assume that you can open the core with gdb, right?
Can you go up to #11 (DTLSICETransport.cpp:1456) and print the value of packet
, header
and extension
?
auto rtx = std::make_shared<RTPPacket>(packet->GetMedia(),packet->GetCodec(),header,extension);
Also, could you provide a bit more context on how are able to generate the crash? OS,which demo are you using, etc..
Ubuntu 16.04.4 LTS. the simulcast demo as server, a firefox browser provides input stream, and another server acts as tens of clients to receive the same stream.
How are you sending the simulcast stream to the othere server? can you share your code?
how to act as clients #8
Can you try again with latest code (both demo and media server)?
I have been doing a major rewrite on the affected code, so it may have solved it.
v0.29.3 the same. 30 clients:not crash at clients startup, 40 clients crashed
I don't see where do you send or receive any actual data from the client or server (except the commented out player)
Could you upload your code to a couple of temporal github repos so I can test exactly the same as you?
open a browser to supply the first stream for the room
Thanxs! the good news are that I am able to reproduce the issue.. :)
👍
I am no longer able to reproduce it after the fix. Could you confirm it also solves the seg fault on your side?
Thank you for the report and the support for troubleshooting it!
when simulated about 40 peers to play a stream, this happen Error in `node': corrupted size vs. prev_size: 0x00000000025998d0 ======= Backtrace: ========= /lib/x86_64-linux-gnu/libc.so.6(+0x777e5)[0x7fea5e0b17e5] /lib/x86_64-linux-gnu/libc.so.6(+0x7e9dc)[0x7fea5e0b89dc] /lib/x86_64-linux-gnu/libc.so.6(+0x81cde)[0x7fea5e0bbcde] /lib/x86_64-linux-gnu/libc.so.6(__libc_malloc+0x54)[0x7fea5e0be184] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_Znwm+0x18)[0x7fea5ebcde78]