about summary refs log tree commit diff stats
path: root/ignore.c
diff options
context:
space:
mode:
authorRory Bradford <roryrjb@gmail.com>2022-11-19 11:11:26 +0000
committerRory Bradford <roryrjb@gmail.com>2022-11-19 11:18:40 +0000
commit0f92f7352d1964a9859868439e8ded2c4de2111e (patch)
tree14c690402fa28c3b465ec00d2fe767054a1a3331 /ignore.c
parentfbb7c479de91b197c6c501c2023bf564a6a7610f (diff)
downloadrf-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.c5
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