1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-27 00:29:31 +00:00

xstack bump to 512

This commit is contained in:
rumbledethumps 2024-02-17 15:47:51 -08:00
parent b8b263b38c
commit f42e6a26b2
4 changed files with 4 additions and 4 deletions

View File

@ -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;

View File

@ -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) {

View File

@ -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;

View File

@ -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;) {