From 8c041cd115dba7d89c074751373b13144fca8c7e Mon Sep 17 00:00:00 2001 From: FRIGN Date: Wed, 18 Feb 2015 22:04:32 +0100 Subject: [PATCH] Don't terminate du(1) if chdir(2) fails --- du.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/du.c b/du.c index 1617801..56b4b9f 100644 --- a/du.c +++ b/du.c @@ -51,7 +51,7 @@ push(const char *path) cwd = agetcwd(); if (chdir(path) < 0) - eprintf("chdir: %s:", path); + weprintf("chdir: %s:", path); return cwd; } @@ -59,7 +59,7 @@ static void pop(char *path) { if (chdir(path) < 0) - eprintf("chdir: %s:", path); + weprintf("chdir: %s:", path); free(path); }