From ffd4d9e98fcdd49abb153ef99876f87fcba1ea6e Mon Sep 17 00:00:00 2001 From: Zeex Date: Sun, 3 Jul 2016 02:16:36 +0600 Subject: [PATCH] Fix unused chdir() result value warning --- source/compiler/sc1.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/compiler/sc1.c b/source/compiler/sc1.c index d7f2861..61a62f8 100644 --- a/source/compiler/sc1.c +++ b/source/compiler/sc1.c @@ -1037,7 +1037,8 @@ static void parseoptions(int argc,char **argv,char *oname,char *ename,char *pnam if (ptr[1]==':') dos_setdrive(toupper(*ptr)-'A'+1); /* set active drive */ #endif - chdir(ptr); + if (chdir(ptr)==-1) + ; /* silently ignore chdir() errors */ break; case 'd': switch (*option_value(ptr)) {