From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11681 invoked by alias); 12 Jun 2008 18:45:38 -0000 Received: (qmail 11648 invoked by uid 9582); 12 Jun 2008 18:45:37 -0000 Date: Thu, 12 Jun 2008 18:45:00 -0000 Message-ID: <20080612184537.11631.qmail@sourceware.org> From: rpeterso@sourceware.org To: cluster-cvs@sources.redhat.com, cluster-devel@redhat.com Subject: Cluster Project branch, master, updated. cluster-2.99.04-21-gb1e2d32 X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Oldrev: bad45f88207f1586eee6270f030f51527da7c79a X-Git-Newrev: b1e2d32853cf569e363ef8b8f71fbdc5eda36aec Mailing-List: contact cluster-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: cluster-cvs-owner@sourceware.org X-SW-Source: 2008-q2/txt/msg00484.txt.bz2 This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Cluster Project". http://sources.redhat.com/git/gitweb.cgi?p=cluster.git;a=commitdiff;h=b1e2d32853cf569e363ef8b8f71fbdc5eda36aec The branch, master has been updated via b1e2d32853cf569e363ef8b8f71fbdc5eda36aec (commit) from bad45f88207f1586eee6270f030f51527da7c79a (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit b1e2d32853cf569e363ef8b8f71fbdc5eda36aec Author: Bob Peterson Date: Thu Jun 12 13:42:27 2008 -0500 Fix gfs_tool build warnings ----------------------------------------------------------------------- Summary of changes: gfs/gfs_tool/counters.c | 2 +- gfs/gfs_tool/main.c | 2 +- gfs/gfs_tool/misc.c | 6 ++---- gfs/gfs_tool/sb.c | 11 +++++------ 4 files changed, 9 insertions(+), 12 deletions(-) diff --git a/gfs/gfs_tool/counters.c b/gfs/gfs_tool/counters.c index f0da2df..641428a 100644 --- a/gfs/gfs_tool/counters.c +++ b/gfs/gfs_tool/counters.c @@ -186,7 +186,7 @@ print_counters(int argc, char **argv) die("can't get counters: %s\n", strerror(errno)); if (debug) - write(STDOUT_FILENO, data, error); + error = write(STDOUT_FILENO, data, error); parse_lines(data, error); diff --git a/gfs/gfs_tool/main.c b/gfs/gfs_tool/main.c index d71373f..3de8580 100644 --- a/gfs/gfs_tool/main.c +++ b/gfs/gfs_tool/main.c @@ -110,7 +110,7 @@ print_usage(void) int x; for (x = 0; usage[x][0]; x++) - printf(usage[x]); + printf("%s", usage[x]); } /** diff --git a/gfs/gfs_tool/misc.c b/gfs/gfs_tool/misc.c index 2ec3ca6..bd699f2 100644 --- a/gfs/gfs_tool/misc.c +++ b/gfs/gfs_tool/misc.c @@ -158,7 +158,7 @@ print_lockdump(int argc, char **argv) close(fd); - write(STDOUT_FILENO, data, count); + x = write(STDOUT_FILENO, data, count); free(data); } @@ -640,9 +640,7 @@ reclaim_metadata(int argc, char **argv) if (!override) { printf("Don't do this if this file system is being exported by NFS (on any machine).\n"); printf("\nAre you sure you want to proceed? [y/n] "); - fgets(buf, 255, stdin); - - if (buf[0] != 'y') + if (fgets(buf, 255, stdin) == NULL || buf[0] != 'y') die("aborted\n"); printf("\n"); diff --git a/gfs/gfs_tool/sb.c b/gfs/gfs_tool/sb.c index 9a999f4..130e039 100644 --- a/gfs/gfs_tool/sb.c +++ b/gfs/gfs_tool/sb.c @@ -48,7 +48,8 @@ do_sb(int argc, char **argv) { char *device, *field, *newval = NULL; int fd; - unsigned char buf[GFS_BASIC_BLOCK], input[256]; + unsigned char buf[GFS_BASIC_BLOCK]; + char input[256]; struct gfs_sb sb; if (optind == argc) @@ -75,9 +76,7 @@ do_sb(int argc, char **argv) if (newval && !override) { printf("You shouldn't change any of these values if the filesystem is mounted.\n"); printf("\nAre you sure? [y/n] "); - fgets(input, 255, stdin); - - if (input[0] != 'y') + if (fgets(input, 255, stdin) == NULL || input[0] != 'y') die("aborted\n"); printf("\n"); @@ -86,7 +85,7 @@ do_sb(int argc, char **argv) do_lseek(fd, GFS_SB_ADDR * GFS_BASIC_BLOCK); do_read(fd, buf, GFS_BASIC_BLOCK); - gfs_sb_in(&sb, buf); + gfs_sb_in(&sb, (char *)buf); if (sb.sb_header.mh_magic != GFS_MAGIC || sb.sb_header.mh_type != GFS_METATYPE_SB) @@ -139,7 +138,7 @@ do_sb(int argc, char **argv) die("unknown field %s\n", field); if (newval) { - gfs_sb_out(&sb, buf); + gfs_sb_out(&sb, (char *)buf); do_lseek(fd, GFS_SB_ADDR * GFS_BASIC_BLOCK); do_write(fd, buf, GFS_BASIC_BLOCK); hooks/post-receive -- Cluster Project