unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: "Göran Weinholt" <goran@weinholt.se>
Cc: 15100-done@debbugs.gnu.org
Subject: bug#15100: Division by zero in bytevector->uint-list
Date: Fri, 16 Aug 2013 23:19:15 -0400	[thread overview]
Message-ID: <87pptdgg24.fsf@tines.lan> (raw)
In-Reply-To: <87li438bev.fsf@industria.weinholt.se> ("Göran Weinholt"'s message of "Thu, 15 Aug 2013 13:02:16 +0200")

Göran Weinholt <goran@weinholt.se> writes:

> the bytevector->uint-list procedure from (rnrs) can crash Guile through
> a division by zero:
>
> scheme@(guile-user)> (import (rnrs))
> scheme@(guile-user)> (bytevector->uint-list #vu8(0) 'x 0)
> Floating point exception
>
> The same happens with bytevector->sint-list.

Fixed in 088cfb7d761b01a2620d78f10e8dbcaa07485a32.

> These procedures also do not check that the length of the bytevector
> is divisible by the size.

I don't think we can fix this in stable-2.0, because some existing code
might depend on our current permissive behavior.  However, I fixed it on
the master branch in c099201da1de71652b9791fb0a3a863b6d3c355d.

    Thanks!
      Mark





      reply	other threads:[~2013-08-17  3:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-15 11:02 bug#15100: Division by zero in bytevector->uint-list Göran Weinholt
2013-08-17  3:19 ` Mark H Weaver [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=87pptdgg24.fsf@tines.lan \
    --to=mhw@netris.org \
    --cc=15100-done@debbugs.gnu.org \
    --cc=goran@weinholt.se \
    /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).