From 6d7c440288a65b9eccc65d2b27261c0b3625d1e9 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Thu, 15 Oct 2009 15:44:45 +0200 Subject: [PATCH] fix scm_array_handle_ref signedness fix * libguile/inline.h: Fix signedness fix. --- libguile/inline.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libguile/inline.h b/libguile/inline.h index a8f24d44f..eaa7494d6 100644 --- a/libguile/inline.h +++ b/libguile/inline.h @@ -243,7 +243,7 @@ SCM_C_EXTERN_INLINE SCM scm_array_handle_ref (scm_t_array_handle *h, ssize_t p) { - if (SCM_UNLIKELY (p < 0 && -p > (ssize_t) h->base)) + if (SCM_UNLIKELY (p < 0 && ((size_t)-p) > h->base)) /* catch overflow */ scm_out_of_range (NULL, scm_from_ssize_t (p)); /* perhaps should catch overflow here too */