diff options
| author | @syxhe <https://t.me/syxhe> | 2025-04-10 18:58:30 -0500 |
|---|---|---|
| committer | @syxhe <https://t.me/syxhe> | 2025-04-10 18:58:30 -0500 |
| commit | d9d142a7ad0bade65b6f8b777259e203dc6d5301 (patch) | |
| tree | 51e174696bb4397e97b10748a21d67ca5e4f971e /src/shared.c | |
| parent | e5454e63a086e549f54c23a686ff300b99a83b58 (diff) | |
Overhaul makefile
Diffstat (limited to 'src/shared.c')
| -rw-r--r-- | src/shared.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared.c b/src/shared.c index 093e766..bec0354 100644 --- a/src/shared.c +++ b/src/shared.c | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | #include <errno.h> | 6 | #include <errno.h> |
| 7 | #include <error.h> | 7 | #include <error.h> |
| 8 | 8 | ||
| 9 | static enum XALLOC_TYPE { | 9 | enum XALLOC_TYPE { |
| 10 | XALLOC_INVAL, // Default when unset | 10 | XALLOC_INVAL, // Default when unset |
| 11 | 11 | ||
| 12 | XALLOC_MALLOC, | 12 | XALLOC_MALLOC, |
| @@ -120,7 +120,7 @@ int rwbuf(char **str, unsigned long int initsize, int fd) { | |||
| 120 | int wwbuf(int fd, const unsigned char *buf, int len) { | 120 | int wwbuf(int fd, const unsigned char *buf, int len) { |
| 121 | int total = 0; | 121 | int total = 0; |
| 122 | int left = len; | 122 | int left = len; |
| 123 | int n; | 123 | int n = -1; |
| 124 | 124 | ||
| 125 | while(total < len) { | 125 | while(total < len) { |
| 126 | if((n = write(fd, buf + total, left)) < 0) | 126 | if((n = write(fd, buf + total, left)) < 0) |
