* mandoc: Cast the return value of chdir(2) to void.
@ 2017-07-26 10:22 schwarze
0 siblings, 0 replies; only message in thread
From: schwarze @ 2017-07-26 10:22 UTC (permalink / raw)
To: source
Log Message:
-----------
Cast the return value of chdir(2) to void. We already have a comment
above explaining to human auditors why no error checking is needed
here, so it's only fair to tell the compiler, too.
Worried compiler reported by Michael <Stapelberg at debian>.
Modified Files:
--------------
mandoc:
main.c
Revision Data
-------------
Index: main.c
===================================================================
RCS file: /home/cvs/mandoc/mandoc/main.c,v
retrieving revision 1.300
retrieving revision 1.301
diff -Lmain.c -Lmain.c -u -p -r1.300 -r1.301
--- main.c
+++ main.c
@@ -478,7 +478,7 @@ main(int argc, char *argv[])
parse(&curp, fd, *argv);
else if (resp->form == FORM_SRC) {
/* For .so only; ignore failure. */
- chdir(conf.manpath.paths[resp->ipath]);
+ (void)chdir(conf.manpath.paths[resp->ipath]);
parse(&curp, fd, resp->file);
} else
passthrough(resp->file, fd,
--
To unsubscribe send an email to source+unsubscribe@mandoc.bsd.lv
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-07-26 10:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-26 10:22 mandoc: Cast the return value of chdir(2) to void schwarze
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).