summaryrefslogtreecommitdiff
path: root/libguile/srfi-13.c
diff options
context:
space:
mode:
authorMichael Gran <spk121@yahoo.com>2009-08-20 07:23:22 -0700
committerMichael Gran <spk121@yahoo.com>2009-08-20 08:14:28 -0700
commit53a468dd8c2d8a6552b1b7ed4025414fc219d21d (patch)
tree860562d47b7d11c7c2a33df44d19bc0f3677b19c /libguile/srfi-13.c
parentf846bd1a8f0e0d366fb8bb6944598641bc3dd246 (diff)
downloadguile-53a468dd8c2d8a6552b1b7ed4025414fc219d21d.tar.gz
type limits error in string-tabulate
* libguile/srfi-13.c (scm_string_tabulate): test range of signed integer before casting it to unsigned size_t
Diffstat (limited to 'libguile/srfi-13.c')
-rw-r--r--libguile/srfi-13.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libguile/srfi-13.c b/libguile/srfi-13.c
index 1eb456322..4faa377d0 100644
--- a/libguile/srfi-13.c
+++ b/libguile/srfi-13.c
@@ -227,8 +227,8 @@ SCM_DEFINE (scm_string_tabulate, "string-tabulate", 2, 0, 0,
proc_tramp = scm_trampoline_1 (proc);
SCM_ASSERT (proc_tramp, proc, SCM_ARG1, FUNC_NAME);
+ SCM_ASSERT_RANGE (2, len, scm_to_int (len) >= 0);
clen = scm_to_size_t (len);
- SCM_ASSERT_RANGE (2, len, clen >= 0);
{
/* This function is more complicated than necessary for the sake