unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Andy Wingo <wingo@igalia.com>
To: Thomas Danckaert <post@thomasdanckaert.be>
Cc: ludo@gnu.org, 26013@debbugs.gnu.org
Subject: bug#26013: (srfi srfi-37) chokes on empty string parameter
Date: Wed, 19 Apr 2017 17:13:25 +0200	[thread overview]
Message-ID: <87inm0l9be.fsf@igalia.com> (raw)
In-Reply-To: <20170307.163454.2259447634066961490.post@thomasdanckaert.be> (Thomas Danckaert's message of "Tue, 07 Mar 2017 16:34:54 +0100 (CET)")

On Tue 07 Mar 2017 16:34, Thomas Danckaert <post@thomasdanckaert.be> writes:

> It looks like Guile's srfi-37 implementation doesn't process empty
> string arguments correctly.  For example, here's a stacktrace I get when
> executing guix system list-generations "":
>
> $ guix system list-generations ""
> Backtrace:
> In ice-9/boot-9.scm:
>  160: 15 [catch #t #<catch-closure 188c1c0> ...]
> In unknown file:
>    ?: 14 [apply-smob/1 #<catch-closure 188c1c0>]
> In ice-9/boot-9.scm:
>   66: 13 [call-with-prompt prompt0 ...]
> In ice-9/eval.scm:
>  432: 12 [eval # #]
> In ice-9/boot-9.scm:
> 2404: 11 [save-module-excursion #<procedure 18af900 at
> ice-9/boot-9.scm:4051:3 ()>]
> 4056: 10 [#<procedure 18af900 at ice-9/boot-9.scm:4051:3 ()>]
> 1727: 9 [%start-stack load-stack ...]
> 1732: 8 [#<procedure 18c3b70 ()>]
> In unknown file:
>    ?: 7 [primitive-load
> "/gnu/store/hnbqdmfh1bwma8nmpai6ci76h5j6bl7j-guix-0.12.0-4.d9da/bin/.guix-real"]
> In guix/ui.scm:
> 1228: 6 [run-guix-command system "list-generations" ""]
> In ice-9/boot-9.scm:
>  160: 5 [catch srfi-34 #<procedure 47e1580 at guix/ui.scm:432:2 ()> ...]
>  160: 4 [catch system-error ...]
> In guix/scripts/system.scm:
>  947: 3 [#<procedure 47e2b10 at guix/scripts/system.scm:946:2 ()>]
> In ice-9/boot-9.scm:
>  160: 2 [catch misc-error #<procedure 47e4c00 at guix/scripts.scm:48:4
> ()> ...]
> In srfi/srfi-37.scm:
>  220: 1 [next-arg]
> In unknown file:
>    ?: 0 [string-ref "" 0]
>
> ERROR: In procedure string-ref:
> ERROR: Value out of range: 0

Sounds like the right diagnosis to me.  Want to submit a patch? :)

Andy





  reply	other threads:[~2017-04-19 15:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-07 15:34 bug#26013: (srfi srfi-37) chokes on empty string parameter Thomas Danckaert
2017-04-19 15:13 ` Andy Wingo [this message]
2017-04-19 16:32   ` Thomas Danckaert
2017-04-20  8:59     ` Andy Wingo

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=87inm0l9be.fsf@igalia.com \
    --to=wingo@igalia.com \
    --cc=26013@debbugs.gnu.org \
    --cc=ludo@gnu.org \
    --cc=post@thomasdanckaert.be \
    /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).