[Pkg-javascript-devel] Bug#1076350: Bug#1076350: simple way to reproduce segfault in nodejs when using browserify in i386
Jérémy Lal
kapouer at melix.org
Thu Jul 18 16:09:37 BST 2024
Le jeu. 18 juil. 2024 à 17:03, Сергей Сёмин <syominsergey at gmail.com> a
écrit :
> I built source package nodejs_18.19.0+dfsg-6~deb12u2 in Debian
> Bookworm i386 and installed result deb packages into system.
> Packages with dbgsym were also installed.
> Then I tried to reproduce segfault with simple way explained earlier
> and now I see better more informative backtrace with mentioned source
> files because of available debug symbols:
>
> root at debian-bookworm-i386:~/browserify_helloworld# coredumpctl -1 debug
> PID: 22462 (node)
> UID: 0 (root)
> GID: 0 (root)
> Signal: 11 (SEGV)
> Timestamp: Thu 2024-07-18 17:42:19 MSK (43s ago)
> Command Line: node /usr/bin/browserify main.js -o bundle.js
> Executable: /usr/bin/node
> Control Group: /user.slice/user-0.slice/session-1.scope
> Unit: session-1.scope
> Slice: user-0.slice
> Session: 1
> Owner UID: 0 (root)
> Boot ID: aabb14f30d9d467d9389c47f962245e5
> Machine ID: bb88a0eb919c40a690e344da5d477cfb
> Hostname: debian-bookworm-i386
> Storage:
>
> /var/lib/systemd/coredump/core.node.0.aabb14f30d9d467d9389c47f962245e5.22462.1721313739000000.zst
> (present)
> Size on Disk: 4.0M
> Message: Process 22462 (node) of user 0 dumped core.
>
> Stack trace of thread 22462:
> #0 0x00000000b5858507
> _ZNKSt14default_deleteIN4node2fs18FSContinuationDataEEclEPS2_
> (libnode.so.108 + 0x858507)
> #1 0x00000000b5871a4d _ZN4node2fs13FSReqCallbackD4Ev
> (libnode.so.108 + 0x871a4d)
> #2 0x00000000b584bc52
> _ZN4node17BaseObjectPtrImplINS_7ReqWrapI7uv_fs_sEELb0EED4Ev
> (libnode.so.108 + 0x84bc52)
> #3 0x00000000b7c67620 n/a (libuv.so.1 + 0x9620)
> #4 0x00000000b7c6b24a n/a (libuv.so.1 + 0xd24a)
> #5 0x00000000b7c8099b n/a (libuv.so.1 + 0x2299b)
> #6 0x00000000b7c6bc83 uv_run (libuv.so.1 + 0xdc83)
> #7 0x00000000b577424a
> _ZN4node13SpinEventLoopEPNS_11EnvironmentE (libnode.so.108 + 0x77424a)
> #8 0x00000000b58a185c
> _ZN4node16NodeMainInstance3RunEPiPNS_11EnvironmentE (libnode.so.108 +
> 0x8a185c)
> #9 0x00000000b58a1cb9
> _ZN4node16NodeMainInstance3RunEv (libnode.so.108 + 0x8a1cb9)
> #10 0x00000000b5807951
>
> _ZN4node22LoadSnapshotDataAndRunEPPKNS_12SnapshotDataEPKNS_20InitializationResultE
> (libnode.so.108 + 0x807951)
> #11 0x00000000b580b70e _ZN4node5StartEiPPc
> (libnode.so.108 + 0x80b70e)
> #12 0x0000000000439087 main (node + 0x1087)
> #13 0x00000000b7cd42d5 __libc_start_call_main
> (libc.so.6 + 0x232d5)
> #14 0x00000000b7cd4398 __libc_start_main_impl
> (libc.so.6 + 0x23398)
> #15 0x00000000004390c7 _start (node + 0x10c7)
>
> Stack trace of thread 22465:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b58ce222
> _ZN4node16LibuvMutexTraits9cond_waitEP14pthread_cond_tP15pthread_mutex_t
> (libnode.so.108 + 0x8ce222)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22464:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b58ce222
> _ZN4node16LibuvMutexTraits9cond_waitEP14pthread_cond_tP15pthread_mutex_t
> (libnode.so.108 + 0x8ce222)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22463:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dd2bc3 epoll_wait (libc.so.6 + 0x121bc3)
> #2 0x00000000b7c80c8e n/a (libuv.so.1 + 0x22c8e)
> #3 0x00000000b7c6bc83 uv_run (libuv.so.1 + 0xdc83)
> #4 0x00000000b58d3378
> _ZN4node23WorkerThreadsTaskRunner20DelayedTaskScheduler3RunEv
> (libnode.so.108 + 0x8d3378)
> #5 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #6 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22470:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b7c66f5d n/a (libuv.so.1 + 0x8f5d)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22466:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b58ce222
> _ZN4node16LibuvMutexTraits9cond_waitEP14pthread_cond_tP15pthread_mutex_t
> (libnode.so.108 + 0x8ce222)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22468:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d41912 do_futex_wait (libc.so.6 + 0x90912)
> #4 0x00000000b7d419bb __new_sem_wait_slow64
> (libc.so.6 + 0x909bb)
> #5 0x00000000b7c7a72b uv_sem_wait (libuv.so.1 + 0x1c72b)
> #6 0x00000000b597f6e3 StartIoThreadMain
> (libnode.so.108 + 0x97f6e3)
> #7 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #8 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22469:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b7c66f5d n/a (libuv.so.1 + 0x8f5d)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22467:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b58ce222
> _ZN4node16LibuvMutexTraits9cond_waitEP14pthread_cond_tP15pthread_mutex_t
> (libnode.so.108 + 0x8ce222)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22472:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b7c66f5d n/a (libuv.so.1 + 0x8f5d)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
>
> Stack trace of thread 22471:
> #0 0x00000000b7ee3559 __kernel_vsyscall
> (linux-gate.so.1 + 0x559)
> #1 0x00000000b7dc6bd2 __libc_do_syscall (libc.so.6 +
> 0x115bd2)
> #2 0x00000000b7d355b5 __futex_abstimed_wait_common32
> (libc.so.6 + 0x845b5)
> #3 0x00000000b7d3880e __pthread_cond_wait_common
> (libc.so.6 + 0x8780e)
> #4 0x00000000b7c7a69c uv_cond_wait (libuv.so.1 + 0x1c69c)
> #5 0x00000000b7c66f5d n/a (libuv.so.1 + 0x8f5d)
> #6 0x00000000b7d3935d start_thread (libc.so.6 + 0x8835d)
> #7 0x00000000b7dd4688 __clone3 (libc.so.6 + 0x123688)
> ELF object binary architecture: Intel 80386
>
> GNU gdb (Debian 13.1-3) 13.1
> Copyright (C) 2023 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <
> http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.
> Type "show copying" and "show warranty" for details.
> This GDB was configured as "i686-linux-gnu".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <https://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
> <http://www.gnu.org/software/gdb/documentation/>.
>
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from /usr/bin/node...
> Reading symbols from
> /usr/lib/debug/.build-id/85/5948c7d2e9357505bc0caccfa1291cdc32930a.debug...
> [New LWP 22462]
> [New LWP 22465]
> [New LWP 22464]
> [New LWP 22463]
> [New LWP 22470]
> [New LWP 22466]
> [New LWP 22468]
> [New LWP 22469]
> [New LWP 22467]
> [New LWP 22472]
> [New LWP 22471]
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".
> Core was generated by `node /usr/bin/browserify main.js -o bundle.js'.
> Program terminated with signal SIGSEGV, Segmentation fault.
> #0 0xb5858507 in
> std::default_delete<node::fs::FSContinuationData>::operator() () at
> /usr/include/c++/12/bits/unique_ptr.h:95
> 95 delete __ptr;
> [Current thread is 1 (Thread 0xb4cef780 (LWP 22462))]
> (gdb) bt
> #0 0xb5858507 in
> std::default_delete<node::fs::FSContinuationData>::operator() () at
> /usr/include/c++/12/bits/unique_ptr.h:95
> #1 std::unique_ptr<node::fs::FSContinuationData,
> std::default_delete<node::fs::FSContinuationData> >::~unique_ptr () at
> /usr/include/c++/12/bits/unique_ptr.h:396
> #2 node::fs::FSReqBase::~FSReqBase () at ../src/node_file.cc:224
> #3 0xb5871a4d in node::fs::FSReqCallback::~FSReqCallback () at
> ../src/node_file.h:175
> #4 node::fs::FSReqCallback::~FSReqCallback () at ../src/node_file.h:175
>
This is something somewhat similar to https://bugs.debian.org/922075#20
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-javascript-devel/attachments/20240718/df036fb2/attachment.htm>
More information about the Pkg-javascript-devel
mailing list