This commit is contained in:
Dale Weiler 2012-11-17 08:54:24 +00:00
parent e062c847cb
commit d0c6e0a481

4
test.c
View file

@ -433,8 +433,8 @@ bool task_propogate(const char *curdir) {
dir = opendir(curdir); dir = opendir(curdir);
while ((files = readdir(dir))) { while ((files = readdir(dir))) {
memset (buffer, 0, sizeof(buffer)); memset (buffer, 0,sizeof(buffer));
snprintf(buffer, 0, "%s/%s", curdir, files->d_name); snprintf(buffer, sizeof(buffer), "%s/%s", curdir, files->d_name);
if (stat(buffer, &directory) == -1) { if (stat(buffer, &directory) == -1) {
con_err("internal error: stat failed, aborting\n"); con_err("internal error: stat failed, aborting\n");