Mercurial > msvpvf
comparison src/common.c @ 48:652343b56a60
Remove the need for <inttypes.h> and <stdbool.h>
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Sun, 22 May 2022 00:08:10 -0400 |
parents | 7cb4ca7cf257 |
children | fcd4b9fe957b |
comparison
equal
deleted
inserted
replaced
47:7cb4ca7cf257 | 48:652343b56a60 |
---|---|
25 if (target == NULL) { | 25 if (target == NULL) { |
26 fclose(source); | 26 fclose(source); |
27 return 1; | 27 return 1; |
28 } | 28 } |
29 | 29 |
30 while (fgetc(source) != EOF) { | 30 while (!feof(source)) { |
31 size_t b = fread(ch, 1, sizeof(ch), source); | 31 size_t b = fread(ch, 1, sizeof(ch), source); |
32 if (b) | 32 if (b) |
33 fwrite(ch, 1, b, target); | 33 fwrite(ch, 1, b, target); |
34 } | 34 } |
35 | 35 |