Module Name: src Committed By: mrg Date: Mon Feb 5 22:14:26 UTC 2018
Modified Files: src/sys/dev: radio.c src/sys/dev/ic: mpt_netbsd.c src/usr.bin/grep: util.c Log Message: fixes for GCC 6.4: - fix an indentation issue in radioioctl(). - fix an indentation issue in mpt_run_xfer(). - grep's printline() has some {} placement issues. To generate a diff of this commit: cvs rdiff -u -r1.28 -r1.29 src/sys/dev/radio.c cvs rdiff -u -r1.34 -r1.35 src/sys/dev/ic/mpt_netbsd.c cvs rdiff -u -r1.18 -r1.19 src/usr.bin/grep/util.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/radio.c diff -u src/sys/dev/radio.c:1.28 src/sys/dev/radio.c:1.29 --- src/sys/dev/radio.c:1.28 Sat Oct 28 03:47:24 2017 +++ src/sys/dev/radio.c Mon Feb 5 22:14:26 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: radio.c,v 1.28 2017/10/28 03:47:24 riastradh Exp $ */ +/* $NetBSD: radio.c,v 1.29 2018/02/05 22:14:26 mrg Exp $ */ /* $OpenBSD: radio.c,v 1.2 2001/12/05 10:27:06 mickey Exp $ */ /* $RuOBSD: radio.c,v 1.7 2001/12/04 06:03:05 tm Exp $ */ @@ -30,7 +30,7 @@ /* This is the /dev/radio driver from OpenBSD */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: radio.c,v 1.28 2017/10/28 03:47:24 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: radio.c,v 1.29 2018/02/05 22:14:26 mrg Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -148,7 +148,7 @@ radioioctl(dev_t dev, u_long cmd, void * if (sc->hw_if->get_info) error = (sc->hw_if->get_info)(sc->hw_hdl, (struct radio_info *)data); - break; + break; case RIOCSINFO: if (sc->hw_if->set_info) error = (sc->hw_if->set_info)(sc->hw_hdl, Index: src/sys/dev/ic/mpt_netbsd.c diff -u src/sys/dev/ic/mpt_netbsd.c:1.34 src/sys/dev/ic/mpt_netbsd.c:1.35 --- src/sys/dev/ic/mpt_netbsd.c:1.34 Tue Jan 30 20:20:38 2018 +++ src/sys/dev/ic/mpt_netbsd.c Mon Feb 5 22:14:26 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: mpt_netbsd.c,v 1.34 2018/01/30 20:20:38 jakllsch Exp $ */ +/* $NetBSD: mpt_netbsd.c,v 1.35 2018/02/05 22:14:26 mrg Exp $ */ /* * Copyright (c) 2003 Wasabi Systems, Inc. @@ -77,7 +77,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: mpt_netbsd.c,v 1.34 2018/01/30 20:20:38 jakllsch Exp $"); +__KERNEL_RCSID(0, "$NetBSD: mpt_netbsd.c,v 1.35 2018/02/05 22:14:26 mrg Exp $"); #include "bio.h" @@ -1093,11 +1093,11 @@ mpt_run_xfer(mpt_softc_t *mpt, struct sc if (mpt->verbose > 1) mpt_print_scsi_io_request(mpt_req); - if (xs->timeout == 0) { - mpt_prt(mpt, "mpt_run_xfer: no timeout specified for request: 0x%x\n", + if (xs->timeout == 0) { + mpt_prt(mpt, "mpt_run_xfer: no timeout specified for request: 0x%x\n", req->index); - xs->timeout = 500; - } + xs->timeout = 500; + } s = splbio(); if (__predict_true((xs->xs_control & XS_CTL_POLL) == 0)) Index: src/usr.bin/grep/util.c diff -u src/usr.bin/grep/util.c:1.18 src/usr.bin/grep/util.c:1.19 --- src/usr.bin/grep/util.c:1.18 Mon Jul 14 21:56:03 2014 +++ src/usr.bin/grep/util.c Mon Feb 5 22:14:26 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: util.c,v 1.18 2014/07/14 21:56:03 christos Exp $ */ +/* $NetBSD: util.c,v 1.19 2018/02/05 22:14:26 mrg Exp $ */ /* $FreeBSD: head/usr.bin/grep/util.c 211496 2010-08-19 09:28:59Z des $ */ /* $OpenBSD: util.c,v 1.39 2010/07/02 22:18:03 tedu Exp $ */ @@ -34,7 +34,7 @@ #endif #include <sys/cdefs.h> -__RCSID("$NetBSD: util.c,v 1.18 2014/07/14 21:56:03 christos Exp $"); +__RCSID("$NetBSD: util.c,v 1.19 2018/02/05 22:14:26 mrg Exp $"); #include <sys/stat.h> #include <sys/types.h> @@ -478,9 +478,10 @@ printline(struct str *line, int sep, reg if (color) fprintf(stdout, "\33[%sm\33[K", color); - fwrite(line->dat + matches[i].rm_so, - matches[i].rm_eo - matches[i].rm_so, 1, - stdout); + fwrite(line->dat + matches[i].rm_so, + matches[i].rm_eo - matches[i].rm_so, 1, + stdout); + if (color) fprintf(stdout, "\33[m\33[K"); a = matches[i].rm_eo;