Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/scsipi Appease gcc3 -Wno-uninitialized (even though ...



details:   https://anonhg.NetBSD.org/src/rev/e24bb64f8a10
branches:  trunk
changeset: 554406:e24bb64f8a10
user:      fredb <fredb%NetBSD.org@localhost>
date:      Mon Oct 27 23:03:05 2003 +0000

description:
Appease gcc3 -Wno-uninitialized (even though blkno is clearly assigned in
each branch of a conditional).

diffstat:

 sys/dev/scsipi/sd.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (27 lines):

diff -r e771f63a7b1e -r e24bb64f8a10 sys/dev/scsipi/sd.c
--- a/sys/dev/scsipi/sd.c       Mon Oct 27 22:48:20 2003 +0000
+++ b/sys/dev/scsipi/sd.c       Mon Oct 27 23:03:05 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sd.c,v 1.210 2003/09/18 06:55:53 mycroft Exp $ */
+/*     $NetBSD: sd.c,v 1.211 2003/10/27 23:03:05 fredb Exp $   */
 
 /*-
  * Copyright (c) 1998, 2003 The NetBSD Foundation, Inc.
@@ -54,7 +54,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sd.c,v 1.210 2003/09/18 06:55:53 mycroft Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sd.c,v 1.211 2003/10/27 23:03:05 fredb Exp $");
 
 #include "opt_scsi.h"
 #include "opt_bufq.h"
@@ -683,6 +683,8 @@
        int s;
        boolean_t sector_aligned;
 
+       blkno = 0;              /* XXX to appease gcc3 */       
+
        SC_DEBUG(sd->sc_periph, SCSIPI_DB2, ("sdstrategy "));
        SC_DEBUG(sd->sc_periph, SCSIPI_DB1,
            ("%ld bytes @ blk %" PRId64 "\n", bp->b_bcount, bp->b_blkno));



Home | Main Index | Thread Index | Old Index