fixed bug that produced an incorrect assertion violation for

(put-bytevector! port bv i j) where i = (bytevector-length bv).
Thanks to Andreas Rottmann.
This commit is contained in:
Abdulaziz Ghuloum 2009-05-24 12:49:53 +03:00
parent ec76547da0
commit 27112fec4e
2 changed files with 3 additions and 3 deletions

View File

@ -2267,7 +2267,7 @@
(if (bytevector? bv)
(if (fixnum? i)
(let ([n (bytevector-length bv)])
(if (and (fx< i n) (fx>= i 0))
(if (and (fx<= i n) (fx>= i 0))
($put-bytevector p bv i (fx- n i))
(die 'put-bytevector "index out of range" i)))
(die 'put-bytevector "invalid index" i))
@ -2276,7 +2276,7 @@
(if (bytevector? bv)
(if (fixnum? i)
(let ([n (bytevector-length bv)])
(if (and (fx< i n) (fx>= i 0))
(if (and (fx<= i n) (fx>= i 0))
(if (fixnum? c)
(if (and (fx>= c 0) (fx>= (fx- n c) i))
($put-bytevector p bv i c)

View File

@ -1 +1 @@
1788
1789