From c6030c6511c69b69a216c893957b01bfc264d365 Mon Sep 17 00:00:00 2001 From: joerg Date: Sun, 19 Mar 1995 13:29:28 +0000 Subject: You will find enclosed some changes to make gcc -Wall more happy in /usr/src/bin. Note that some patches are still needed in that directory. I (Joerg) finished most of Philippe's cleanup. /bin/sh will still need *allot* of work, however. Submitted by: charnier@lirmm.fr (Philippe Charnier) --- bin/pax/gen_subs.c | 4 ++-- bin/pax/options.c | 32 ++++++++++++++++---------------- bin/pax/pat_rep.c | 4 ++-- 3 files changed, 20 insertions(+), 20 deletions(-) (limited to 'bin/pax') diff --git a/bin/pax/gen_subs.c b/bin/pax/gen_subs.c index 85a24b3..d80a2be 100644 --- a/bin/pax/gen_subs.c +++ b/bin/pax/gen_subs.c @@ -34,7 +34,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: gen_subs.c,v 1.2 1994/09/24 02:56:22 davidg Exp $ */ #ifndef lint @@ -135,7 +135,7 @@ ls_list(arcn, now) # ifdef NET2_STAT (void)printf("%4u,%4u ", MAJOR(sbp->st_rdev), # else - (void)printf("%4lu,%4lu ", MAJOR(sbp->st_rdev), + (void)printf("%4lu,%4lu ", (unsigned long)MAJOR(sbp->st_rdev), # endif MINOR(sbp->st_rdev)); else { diff --git a/bin/pax/options.c b/bin/pax/options.c index 986e015..e8e5cc6 100644 --- a/bin/pax/options.c +++ b/bin/pax/options.c @@ -34,7 +34,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: options.c,v 1.2 1994/09/24 02:56:22 davidg Exp $ */ #ifndef lint @@ -90,34 +90,34 @@ static void cpio_usage __P((void)); FSUB fsub[] = { /* 0: OLD BINARY CPIO */ - "bcpio", 5120, sizeof(HD_BCPIO), 1, 0, 0, 1, bcpio_id, cpio_strd, + {"bcpio", 5120, sizeof(HD_BCPIO), 1, 0, 0, 1, bcpio_id, cpio_strd, bcpio_rd, bcpio_endrd, cpio_stwr, bcpio_wr, cpio_endwr, cpio_trail, - rd_wrfile, wr_rdfile, bad_opt, + rd_wrfile, wr_rdfile, bad_opt}, /* 1: OLD OCTAL CHARACTER CPIO */ - "cpio", 5120, sizeof(HD_CPIO), 1, 0, 0, 1, cpio_id, cpio_strd, + {"cpio", 5120, sizeof(HD_CPIO), 1, 0, 0, 1, cpio_id, cpio_strd, cpio_rd, cpio_endrd, cpio_stwr, cpio_wr, cpio_endwr, cpio_trail, - rd_wrfile, wr_rdfile, bad_opt, + rd_wrfile, wr_rdfile, bad_opt}, /* 2: SVR4 HEX CPIO */ - "sv4cpio", 5120, sizeof(HD_VCPIO), 1, 0, 0, 1, vcpio_id, cpio_strd, + {"sv4cpio", 5120, sizeof(HD_VCPIO), 1, 0, 0, 1, vcpio_id, cpio_strd, vcpio_rd, vcpio_endrd, cpio_stwr, vcpio_wr, cpio_endwr, cpio_trail, - rd_wrfile, wr_rdfile, bad_opt, + rd_wrfile, wr_rdfile, bad_opt}, /* 3: SVR4 HEX CPIO WITH CRC */ - "sv4crc", 5120, sizeof(HD_VCPIO), 1, 0, 0, 1, crc_id, crc_strd, + {"sv4crc", 5120, sizeof(HD_VCPIO), 1, 0, 0, 1, crc_id, crc_strd, vcpio_rd, vcpio_endrd, crc_stwr, vcpio_wr, cpio_endwr, cpio_trail, - rd_wrfile, wr_rdfile, bad_opt, + rd_wrfile, wr_rdfile, bad_opt}, /* 4: OLD TAR */ - "tar", 10240, BLKMULT, 0, 1, BLKMULT, 0, tar_id, no_op, + {"tar", 10240, BLKMULT, 0, 1, BLKMULT, 0, tar_id, no_op, tar_rd, tar_endrd, no_op, tar_wr, tar_endwr, tar_trail, - rd_wrfile, wr_rdfile, tar_opt, + rd_wrfile, wr_rdfile, tar_opt}, /* 5: POSIX USTAR */ - "ustar", 10240, BLKMULT, 0, 1, BLKMULT, 0, ustar_id, ustar_strd, + {"ustar", 10240, BLKMULT, 0, 1, BLKMULT, 0, ustar_id, ustar_strd, ustar_rd, tar_endrd, ustar_stwr, ustar_wr, tar_endwr, tar_trail, - rd_wrfile, wr_rdfile, bad_opt, + rd_wrfile, wr_rdfile, bad_opt}, }; #define F_TAR 4 /* format when called as tar */ #define DEFLT 5 /* default write format from list above */ @@ -367,8 +367,8 @@ pax_options(argc, argv) * specify an archive format on write */ tmp.name = optarg; - if (frmt = (FSUB *)bsearch((void *)&tmp, (void *)fsub, - sizeof(fsub)/sizeof(FSUB), sizeof(FSUB), c_frmt)) { + if ((frmt = (FSUB *)bsearch((void *)&tmp, (void *)fsub, + sizeof(fsub)/sizeof(FSUB), sizeof(FSUB), c_frmt))) { flg |= XF; break; } @@ -823,7 +823,7 @@ printflg(flg) int pos = 0; (void)fprintf(stderr,"%s: Invalid combination of options:", argv0); - while (nxt = ffs(flg)) { + while ((nxt = ffs(flg))) { flg = flg >> nxt; pos += nxt; (void)fprintf(stderr, " -%c", flgch[pos-1]); diff --git a/bin/pax/pat_rep.c b/bin/pax/pat_rep.c index 7b712bf..546a945 100644 --- a/bin/pax/pat_rep.c +++ b/bin/pax/pat_rep.c @@ -34,7 +34,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: pat_rep.c,v 1.2 1994/09/24 02:56:24 davidg Exp $ */ #ifndef lint @@ -617,7 +617,7 @@ range_match(pattern, test) int negate; int ok = 0; - if (negate = (*pattern == '!')) + if ((negate = (*pattern == '!'))) ++pattern; while ((c = *pattern++) != ']') { -- cgit v1.1