From 2a6598646824da9d6a957fb5b3e4c6bb40fb6835 Mon Sep 17 00:00:00 2001 From: Venky Shankar Date: Mon, 11 Apr 2011 05:48:36 +0000 Subject: build fixes Signed-off-by: Venky Shankar Signed-off-by: Anand Avati BUG: 2550 (build warnings) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2550 --- libglusterfs/src/statedump.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'libglusterfs/src/statedump.c') diff --git a/libglusterfs/src/statedump.c b/libglusterfs/src/statedump.c index 58d816257..0fd4013ff 100644 --- a/libglusterfs/src/statedump.c +++ b/libglusterfs/src/statedump.c @@ -284,6 +284,7 @@ gf_proc_dump_parse_set_option (char *key, char *value) gf_boolean_t *opt_key = NULL; gf_boolean_t opt_value = _gf_false; char buf[GF_DUMP_MAX_BUF_LEN]; + int ret = -1; if (!strncasecmp (key, "mem", 3)) { opt_key = &dump_options.dump_mem; @@ -307,7 +308,7 @@ gf_proc_dump_parse_set_option (char *key, char *value) //None of dump options match the key, return back snprintf (buf, sizeof (buf), "[Warning]:None of the options " "matched key : %s\n", key); - write (gf_dump_fd, buf, strlen (buf)); + ret = write (gf_dump_fd, buf, strlen (buf)); return -1; } @@ -395,7 +396,7 @@ gf_proc_dump_options_init () } snprintf (dumpbuf, sizeof (dumpbuf), "[Debug]:key=%s, value=%s\n",key,value); - write (gf_dump_fd, dumpbuf, strlen (dumpbuf)); + ret = write (gf_dump_fd, dumpbuf, strlen (dumpbuf)); gf_proc_dump_parse_set_option (key, value); -- cgit