1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-09 21:40:33 +02:00

Fix bug in trampoline_to_c_read

* libguile/ports.c (trampoline_to_c_read): Fix bug comparing SCM
  values.
This commit is contained in:
Andy Wingo 2016-05-10 11:08:41 +02:00
parent d77b50476a
commit 83e5ccb02f

View file

@ -234,7 +234,7 @@ trampoline_to_c_read (SCM port, SCM dst, SCM start, SCM count)
SCM_VALIDATE_OPPORT (1, port);
c_start = scm_to_size_t (start);
c_count = scm_to_size_t (count);
SCM_ASSERT_RANGE (2, start, start <= count);
SCM_ASSERT_RANGE (2, start, c_start <= c_count);
SCM_ASSERT_RANGE (3, count, c_start+c_count <= scm_c_bytevector_length (dst));
return scm_from_size_t