diff options
author | Rory Bradford <roryrjb@gmail.com> | 2022-11-19 11:11:26 +0000 |
---|---|---|
committer | Rory Bradford <roryrjb@gmail.com> | 2022-11-19 11:18:40 +0000 |
commit | 0f92f7352d1964a9859868439e8ded2c4de2111e (patch) | |
tree | 14c690402fa28c3b465ec00d2fe767054a1a3331 /ignore.c | |
parent | fbb7c479de91b197c6c501c2023bf564a6a7610f (diff) | |
download | rf-0f92f7352d1964a9859868439e8ded2c4de2111e.tar.gz |
Full native win32 support
This will now compile with MSVC using the make.bat batch file. It does however bring in some additional third party dependencies: ports of dirent and getopt (something I'd ideally like to work on in the future). Signed-off-by: Rory Bradford <roryrjb@gmail.com>
Diffstat (limited to 'ignore.c')
-rw-r--r-- | ignore.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/ignore.c b/ignore.c index 8bff2ce..9640d0b 100644 --- a/ignore.c +++ b/ignore.c @@ -7,7 +7,6 @@ #include <string.h> #include "ignore.h" -#include "rf.h" static int total_size; @@ -19,13 +18,13 @@ struct ignores *init_ignores(char *path) { return NULL; } - char line[MAX_PATH_LENGTH]; + char line[MAXPATHLEN]; total_size = IGNORE_SIZE; struct ignores *ignores = (struct ignores *)calloc(sizeof(struct ignores), 1); ignores->list = (char **)calloc(sizeof(char *), IGNORE_SIZE); ignores->size = 0; - while (fgets(line, MAX_PATH_LENGTH, ignore) != NULL) { + while (fgets(line, MAXPATHLEN, ignore) != NULL) { /** isspace doesn't necessarily hold true for `\n` for anything * other than the 'C' locale on some platforms, so we have to do * an additional check for this |