cosmetic fixes
This commit is contained in:
parent
1b45536fe2
commit
74be43195d
10
src/port.c
10
src/port.c
|
@ -187,7 +187,7 @@ pic_fread(void *ptr, size_t block, size_t nitems, pic_file *file)
|
||||||
memcpy(dst, file->s, size);
|
memcpy(dst, file->s, size);
|
||||||
memmove(file->s, file->s + size, avail - size);
|
memmove(file->s, file->s + size, avail - size);
|
||||||
file->c -= size;
|
file->c -= size;
|
||||||
break;
|
return block * nitems;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
memcpy(dst, file->s, avail);
|
memcpy(dst, file->s, avail);
|
||||||
|
@ -197,8 +197,6 @@ pic_fread(void *ptr, size_t block, size_t nitems, pic_file *file)
|
||||||
pic_ffill(file);
|
pic_ffill(file);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return block * nitems;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t
|
size_t
|
||||||
|
@ -220,12 +218,10 @@ pic_fwrite(const void *ptr, size_t block, size_t nitems, pic_file *file)
|
||||||
else {
|
else {
|
||||||
memcpy(file->c, dst, size);
|
memcpy(file->c, dst, size);
|
||||||
file->c += size;
|
file->c += size;
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return block * nitems;
|
return block * nitems;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
pic_fgetc(pic_file *file)
|
pic_fgetc(pic_file *file)
|
||||||
|
|
Loading…
Reference in New Issue