summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpgen <p.gen.progs@gmail.com>2016-11-29 00:23:45 +0100
committerpgen <p.gen.progs@gmail.com>2016-11-29 00:23:45 +0100
commit3d309ac28cbca73c6986459163f8dff0c41e8827 (patch)
tree604264839cad47e2dcc6614f1e89306f282e62d8
parente2b6d24fb060899b4901c46f9951c509b40cc07a (diff)
Remove a compiler warning about unused return values
-rw-r--r--smenu.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/smenu.c b/smenu.c
index 9097aa5..b91c9da 100644
--- a/smenu.c
+++ b/smenu.c
@@ -3980,9 +3980,11 @@ char *optstart = START; /* list of characters that start options */
#define TELL(S) { \
if (opterr && opterrfd >= 0) { \
char option = (char) optopt; \
- (void) write(opterrfd, (S), strlen(S)); \
- (void) write(opterrfd, &option, 1); \
- (void) write(opterrfd, "\n", 1); \
+ int rc, dummy; \
+ rc=write(opterrfd, (S), strlen(S)); \
+ rc=write(opterrfd, &option, 1); \
+ rc=write(opterrfd, "\n", 1); \
+ dummy=rc; /* to please the compiler about unused results */ \
} \
return (optbad); \
}