From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 22 18:37:42 2013 Received: (at submit) by debbugs.gnu.org; 22 Mar 2013 22:37:42 +0000 Received: from localhost ([127.0.0.1]:41337 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJAag-0005hx-E8 for submit@debbugs.gnu.org; Fri, 22 Mar 2013 18:37:42 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41079) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJ0uL-0006rm-Ht for submit@debbugs.gnu.org; Fri, 22 Mar 2013 08:17:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UJ0sP-0001nS-S2 for submit@debbugs.gnu.org; Fri, 22 Mar 2013 08:15:20 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:43863) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJ0sP-0001nH-Px for submit@debbugs.gnu.org; Fri, 22 Mar 2013 08:15:17 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52409) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJ0sI-0002CD-Ob for bug-guile@gnu.org; Fri, 22 Mar 2013 08:15:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UJ0sF-0001ka-37 for bug-guile@gnu.org; Fri, 22 Mar 2013 08:15:10 -0400 Received: from karen.lavabit.com ([72.249.41.33]:45227) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJ0sE-0001kO-Ky for bug-guile@gnu.org; Fri, 22 Mar 2013 08:15:07 -0400 Received: from a.earth.lavabit.com (a.earth.lavabit.com [192.168.111.10]) by karen.lavabit.com (Postfix) with ESMTP id 0E67B11BB11 for ; Fri, 22 Mar 2013 07:15:06 -0500 (CDT) Received: from lavabit.com (user-5af43b24.broadband.tesco.net [90.244.59.36]) by lavabit.com with ESMTP id OQOL0BEOOSF1 for ; Fri, 22 Mar 2013 07:15:05 -0500 Received: from 90.244.59.36 (SquirrelMail authenticated user johnanthony) by lavabit.com with HTTP; Fri, 22 Mar 2013 08:15:04 -0400 (EDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=lavabit; d=lavabit.com; b=LTYa0MigegXpj+9OI8/X/i8MPpUfpUNUVUQfx3Vl7TeNBd4t8kYUCPQv4ot8Io6tAGIvvU31ct+h/eNqoQPaLN3Cff+KmpnjIUYqn4bzJFSq1VNhRz+n/miwAAqjb/LuK2jqDffbNcF8FzR0GWJdSo0lTtxnyYFr2uhwyfthzoI=; h=Message-ID:Date:Subject:From:To:User-Agent:MIME-Version:Content-Type:Content-Transfer-Encoding; Message-ID: <8629.90.244.59.36.1363954504.squirrel@lavabit.com> Date: Fri, 22 Mar 2013 08:15:04 -0400 (EDT) Subject: Bug Report: scm_with_guile inside pthread segfault From: johnanthony@lavabit.com To: bug-guile@gnu.org User-Agent: SquirrelMail/1.4.13 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 22 Mar 2013 18:37:37 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.9 (------) Hey, there. I was asked to provide this information to you by the guilefriends in Freenode #guile. This code segfaults and I've been having trouble figuring out why. I'm running Ubuntu 12.10 i686 and I'm happy to help any way I can if you need any more information. Please forgive me if I'm doing a terrible job of this as I've never submitted a bug report before. Version Information: guile 2.0.5-deb+1-3 libgc 1:7.1-9 Example program: ``` #include static void* register_functions(void* data){ int argc =3D 1; char *argv[] =3D {"guile", "--listen=3D54491"}; scm_shell(argc, argv); return NULL; } static void* thread_scheme(void* data) { scm_with_guile(®ister_functions, NULL); return NULL; } int main(void) { pthread_t *threads; pthread_attr_t pthread_custom_attr; threads =3D malloc(sizeof(pthread_t)); pthread_attr_init(&pthread_custom_attr); pthread_create(&threads[0], &pthread_custom_attr, thread_scheme, NULL= ); pthread_join(threads[0], NULL); return 0; } ``` Built with gcc (version 4.7.2) like so: gcc test-program.c -ggdb -o test `pkg-config guile-2.0 --cflags` \ `pkg-config guile-2.0 --libs` And here's the bt: ``` Reading symbols from /home/john/test...done. (gdb) r Starting program: /home/john/test [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1". [New Thread 0xb7a24b40 (LWP 15154)] Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0xb7a24b40 (LWP 15154)] 0xb7c654ef in GC_push_all_eager () from /usr/lib/libgc.so.1 (gdb) thread apply all bt Thread 2 (Thread 0xb7a24b40 (LWP 15154)): #0 0xb7c654ef in GC_push_all_eager () from /usr/lib/libgc.so.1 #1 0xb7c65543 in GC_push_all_stack () from /usr/lib/libgc.so.1 #2 0xb7c6dc4b in GC_push_all_stacks () from /usr/lib/libgc.so.1 #3 0xb7c68724 in GC_default_push_other_roots () from /usr/lib/libgc.so.1 #4 0xb7c66be5 in GC_push_roots () from /usr/lib/libgc.so.1 #5 0xb7c66056 in GC_mark_some () from /usr/lib/libgc.so.1 #6 0xb7c5cf15 in GC_stopped_mark () from /usr/lib/libgc.so.1 #7 0xb7c5d61a in GC_try_to_collect_inner () from /usr/lib/libgc.so.1 #8 0xb7c67e90 in GC_init_inner () from /usr/lib/libgc.so.1 #9 0xb7c67fe4 in GC_init () from /usr/lib/libgc.so.1 #10 0xb7eb9d90 in ?? () from /usr/lib/libguile-2.0.so.22 #11 0xb7ecb5d7 in ?? () from /usr/lib/libguile-2.0.so.22 #12 0xb7f29100 in ?? () from /usr/lib/libguile-2.0.so.22 #13 0xb7f2913e in ?? () from /usr/lib/libguile-2.0.so.22 #14 0xb7c67a6e in GC_call_with_stack_base () from /usr/lib/libgc.so.1 #15 0xb7f2949f in scm_with_guile () from /usr/lib/libguile-2.0.so.22 #16 0x0804879a in thread_scheme (data=3D0x0) at guile-pthread-test.c:14 #17 0xb7e49d4c in start_thread (arg=3D0xb7a24b40) at pthread_create.c:308 #18 0xb7d86d3e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:130 Thread 1 (Thread 0xb7a26b00 (LWP 15149)): #0 0xb7fdd424 in __kernel_vsyscall () #1 0xb7e4ae1c in pthread_join (threadid=3D3080866624, thread_return=3D0x= 0) at pthread_join.c:89 #2 0x0804880c in main () at guile-pthread-test.c:26 (gdb) q ``` From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 23 09:59:05 2013 Received: (at 14035) by debbugs.gnu.org; 23 Mar 2013 13:59:05 +0000 Received: from localhost ([127.0.0.1]:42301 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJOyO-0003F3-J4 for submit@debbugs.gnu.org; Sat, 23 Mar 2013 09:59:05 -0400 Received: from karen.lavabit.com ([72.249.41.33]:34997) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJOyM-0003Ep-QP for 14035@debbugs.gnu.org; Sat, 23 Mar 2013 09:59:03 -0400 Received: from a.earth.lavabit.com (a.earth.lavabit.com [192.168.111.10]) by karen.lavabit.com (Postfix) with ESMTP id A4A6611B88B for <14035@debbugs.gnu.org>; Sat, 23 Mar 2013 08:56:59 -0500 (CDT) Received: from lavabit.com (user-5af43b24.broadband.tesco.net [90.244.59.36]) by lavabit.com with ESMTP id FV2ETDGXNCFY for <14035@debbugs.gnu.org>; Sat, 23 Mar 2013 08:56:59 -0500 Received: from 90.244.59.36 (SquirrelMail authenticated user johnanthony) by lavabit.com with HTTP; Sat, 23 Mar 2013 09:56:58 -0400 (EDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=lavabit; d=lavabit.com; b=JhK+KEJXsSoBn3oDWArz22ueF1M907sZSTyiz8s96/Z4m6ZIng0JZtfcckJ6EHICYaY8Dh5UhtkVwejnYaoQJUF2RKgumcJkwOivh9LGZQw0ou/tb40LTs2uaRmOmXdECtISlE6kQey+zgziFUlBurQftN6on9/2lNKkFfwm0Qo=; h=Message-ID:Date:Subject:From:To:User-Agent:MIME-Version:Content-Type:Content-Transfer-Encoding; Message-ID: <47303.90.244.59.36.1364047018.squirrel@lavabit.com> Date: Sat, 23 Mar 2013 09:56:58 -0400 (EDT) Subject: Fixed in 2.0.7 From: johnanthony@lavabit.com To: 14035@debbugs.gnu.org User-Agent: SquirrelMail/1.4.13 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -1.7 (-) X-Debbugs-Envelope-To: 14035 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.7 (-) I grabbed 2.0.7 to see if it was fixed here and it appears to be. Apologies if I was re-reporting an existing bug that was both known about and fixed. From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 23 21:50:36 2013 Received: (at 14035-done) by debbugs.gnu.org; 24 Mar 2013 01:50:36 +0000 Received: from localhost ([127.0.0.1]:42691 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJa4y-0004SN-4c for submit@debbugs.gnu.org; Sat, 23 Mar 2013 21:50:36 -0400 Received: from world.peace.net ([96.39.62.75]:44831) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UJa4n-0004S7-6k for 14035-done@debbugs.gnu.org; Sat, 23 Mar 2013 21:50:35 -0400 Received: from 209-6-91-212.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com ([209.6.91.212] helo=tines.lan) by world.peace.net with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1UJa2g-00067y-5z; Sat, 23 Mar 2013 21:48:14 -0400 From: Mark H Weaver To: johnanthony@lavabit.com Subject: Re: bug#14035: Fixed in 2.0.7 References: <8629.90.244.59.36.1363954504.squirrel@lavabit.com> <47303.90.244.59.36.1364047018.squirrel@lavabit.com> Date: Sat, 23 Mar 2013 21:48:06 -0400 In-Reply-To: <47303.90.244.59.36.1364047018.squirrel@lavabit.com> (johnanthony@lavabit.com's message of "Sat, 23 Mar 2013 09:56:58 -0400 (EDT)") Message-ID: <87620hd0vd.fsf@tines.lan> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 14035-done Cc: 14035-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Hi John, johnanthony@lavabit.com writes: > I grabbed 2.0.7 to see if it was fixed here and it appears to be. Excellent, thanks for letting us know! > Apologies if I was re-reporting an existing bug that was both known about > and fixed. No need to apologize. Thanks for taking the time to file this report, and for following up :) Regards, Mark From unknown Mon Jun 23 07:53:16 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 21 Apr 2013 11:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator