unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: noxdafox <noxdafox@gmail.com>
Cc: 29275-done@debbugs.gnu.org
Subject: bug#29275: dynamic-link hangs on error
Date: Wed, 22 Nov 2017 16:47:57 +0100	[thread overview]
Message-ID: <873756xqky.fsf@gnu.org> (raw)
In-Reply-To: <f8963d9e-9d93-1afd-abb9-4e3522c11e42@gmail.com> (noxdafox@gmail.com's message of "Sun, 12 Nov 2017 20:16:35 +0200")

Hello,

noxdafox <noxdafox@gmail.com> skribis:

> GNU Guile 2.2.2
> Copyright (C) 1995-2017 Free Software Foundation, Inc.
>
> Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
> This program is free software, and you are welcome to redistribute it
> under certain conditions; type `,show c' for details.
>
> Enter `,help' for help.
> scheme@(guile-user)> (use-modules (system foreign))
> scheme@(guile-user)> (define libc-obj (dynamic-link "nonexisting"))
> ERROR: In procedure dynamic-link:
> ERROR: In procedure dynamic-link: file: "nonexisting", message: "file
> not found"
>
> Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
> scheme@(guile-user) [1]> (define libc-obj (dynamic-link "nonexisting"))
>
> ^^^ here the VM becomes unresponsive.

This is because libguile synchronizes uses of ‘dynamic-link’ with a
non-recursive mutex.  Here, the “inner” ‘dynamic-link’ call occurs while
the mutex is already held by the calling thread, which is why it just
hangs.

Fixed in commit 48d42553ef5a9c2240bc2296d1b38dbfd5fca1ac, which will be
in the next 2.2 release.

Thanks,
Ludo’.





      reply	other threads:[~2017-11-22 15:47 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-12 18:16 bug#29275: dynamic-link hangs on error noxdafox
2017-11-22 15:47 ` Ludovic Courtès [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=873756xqky.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=29275-done@debbugs.gnu.org \
    --cc=noxdafox@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).