diff --git a/extra/terminfo/terminfo.factor b/extra/terminfo/terminfo.factor index d90d07a82e..88734b2fd2 100644 --- a/extra/terminfo/terminfo.factor +++ b/extra/terminfo/terminfo.factor @@ -36,7 +36,7 @@ C: terminfo-header boolean-bytes>> read [ 1 = ] { } map-as ; : read-shorts ( n -- seq' ) - 2 * read 2 [ le> dup 65534 >= [ drop f ] when ] map ; + 2 * read 2 [ signed-le> dup 0 < [ drop f ] when ] map ; : align-even-bytes ( header -- ) [ names-bytes>> ] [ boolean-bytes>> ] bi + odd?