This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
use right type for offset in sysread() or syswrite()
[perl5.git] / pp_sys.c
index c5d63ac..f0a799e 100644 (file)
--- a/pp_sys.c
+++ b/pp_sys.c
@@ -1711,7 +1711,7 @@ PP(pp_sysread)
     }
     if (DO_UTF8(bufsv)) {
        /* convert offset-as-chars to offset-as-bytes */
-       if (offset >= (int)blen)
+       if (offset >= (SSize_t)blen)
            offset += SvCUR(bufsv) - blen;
        else
            offset = utf8_hop((U8 *)buffer,offset) - (U8 *) buffer;