diff options
author | Venky Shankar <venky@gluster.com> | 2011-04-11 05:48:36 +0000 |
---|---|---|
committer | Anand Avati <avati@gluster.com> | 2011-04-11 23:50:28 -0700 |
commit | 2a6598646824da9d6a957fb5b3e4c6bb40fb6835 (patch) | |
tree | 2a432e056f4803967569f58f2d70e9c63e2ef306 /libglusterfs/src | |
parent | cfd85789c44ce3f88d6bf87d7b0a47dafb8c6d57 (diff) |
build fixes
Signed-off-by: Venky Shankar <venky@gluster.com>
Signed-off-by: Anand Avati <avati@gluster.com>
BUG: 2550 (build warnings)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2550
Diffstat (limited to 'libglusterfs/src')
-rw-r--r-- | libglusterfs/src/event.h | 2 | ||||
-rw-r--r-- | libglusterfs/src/statedump.c | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/libglusterfs/src/event.h b/libglusterfs/src/event.h index 57884d173..eb4266365 100644 --- a/libglusterfs/src/event.h +++ b/libglusterfs/src/event.h @@ -32,7 +32,7 @@ struct event_ops; struct event_data { int fd; int idx; -} __attribute__ ((__packed__)); +} __attribute__ ((__packed__, __may_alias__)); typedef int (*event_handler_t) (int fd, int idx, void *data, 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); |