diff --git a/libsrc/rp6502/read.c b/libsrc/rp6502/read.c index eb96f779c..87a9bbf7d 100644 --- a/libsrc/rp6502/read.c +++ b/libsrc/rp6502/read.c @@ -5,7 +5,7 @@ int __fastcall__ read (int fildes, void* buf, unsigned count) { int total = 0; while (count) { - unsigned blockcount = (count > 256) ? 256 : count; + unsigned blockcount = (count > 512) ? 512 : count; int bytes_read = read_xstack (&((char*)buf)[total], blockcount, fildes); if (bytes_read < 0) { return bytes_read; diff --git a/libsrc/rp6502/sysrename.c b/libsrc/rp6502/sysrename.c index 96eca24cf..46bdd8b31 100644 --- a/libsrc/rp6502/sysrename.c +++ b/libsrc/rp6502/sysrename.c @@ -7,7 +7,7 @@ unsigned char __fastcall__ _sysrename (const char* oldpath, const char* newpath) size_t oldpathlen, newpathlen; oldpathlen = strlen (oldpath); newpathlen = strlen (newpath); - if (oldpathlen + newpathlen > 254) { + if (oldpathlen + newpathlen > 510) { return _mappederrno (EINVAL); } while (oldpathlen) { diff --git a/libsrc/rp6502/write.c b/libsrc/rp6502/write.c index 11241dab5..23877b6e8 100644 --- a/libsrc/rp6502/write.c +++ b/libsrc/rp6502/write.c @@ -5,7 +5,7 @@ int __fastcall__ write (int fildes, const void* buf, unsigned count) { int ax, total = 0; while (count) { - int blockcount = (count > 256) ? 256 : count; + int blockcount = (count > 512) ? 512 : count; ax = write_xstack (&((char*)buf)[total], blockcount, fildes); if (ax < 0) { return ax; diff --git a/libsrc/rp6502/write_xstack.c b/libsrc/rp6502/write_xstack.c index ff979899d..29285a87e 100644 --- a/libsrc/rp6502/write_xstack.c +++ b/libsrc/rp6502/write_xstack.c @@ -4,7 +4,7 @@ int __fastcall__ write_xstack (const void* buf, unsigned count, int fildes) { unsigned i; - if (count > 256) { + if (count > 512) { return _mappederrno (EINVAL); } for (i = count; i;) {