Date: Wed, 1 May 2013 04:37:35 +0000 (UTC) From: Eitan Adler <eadler@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r250131 - in head/sys: arm/broadcom/bcm2835 cam/ctl net netpfil/ipfw Message-ID: <201305010437.r414bZiJ064423@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: eadler Date: Wed May 1 04:37:34 2013 New Revision: 250131 URL: http://svnweb.freebsd.org/changeset/base/250131 Log: Correct a few sizeof()s Submitted by: swildner@DragonFlyBSD.org Reviewed by: alfred Modified: head/sys/arm/broadcom/bcm2835/bcm2835_dma.c head/sys/cam/ctl/ctl_frontend_internal.c head/sys/net/if_spppsubr.c head/sys/netpfil/ipfw/ip_dummynet.c Modified: head/sys/arm/broadcom/bcm2835/bcm2835_dma.c ============================================================================== --- head/sys/arm/broadcom/bcm2835/bcm2835_dma.c Wed May 1 01:50:33 2013 (r250130) +++ head/sys/arm/broadcom/bcm2835/bcm2835_dma.c Wed May 1 04:37:34 2013 (r250131) @@ -198,7 +198,7 @@ bcm_dma_reset(device_t dev, int ch) /* Reset control block */ cb = sc->sc_dma_ch[ch].cb; - bzero(cb, sizeof(cb)); + bzero(cb, sizeof(*cb)); cb->info = INFO_WAIT_RESP; } Modified: head/sys/cam/ctl/ctl_frontend_internal.c ============================================================================== --- head/sys/cam/ctl/ctl_frontend_internal.c Wed May 1 01:50:33 2013 (r250130) +++ head/sys/cam/ctl/ctl_frontend_internal.c Wed May 1 04:37:34 2013 (r250131) @@ -248,7 +248,7 @@ cfi_init(void) sizeof(struct cfi_lun_io), CTL_PORT_PRIV_SIZE); } - memset(softc, 0, sizeof(softc)); + memset(softc, 0, sizeof(*softc)); mtx_init(&softc->lock, "CTL frontend mutex", NULL, MTX_DEF); softc->flags |= CTL_FLAG_MASTER_SHELF; Modified: head/sys/net/if_spppsubr.c ============================================================================== --- head/sys/net/if_spppsubr.c Wed May 1 01:50:33 2013 (r250130) +++ head/sys/net/if_spppsubr.c Wed May 1 04:37:34 2013 (r250131) @@ -3596,7 +3596,7 @@ sppp_ipv6cp_RCR(struct sppp *sp, struct continue; } - bzero(&suggestaddr, sizeof(&suggestaddr)); + bzero(&suggestaddr, sizeof(suggestaddr)); if (collision && nohisaddr) { /* collision, hisaddr unknown - Conf-Rej */ type = CONF_REJ; Modified: head/sys/netpfil/ipfw/ip_dummynet.c ============================================================================== --- head/sys/netpfil/ipfw/ip_dummynet.c Wed May 1 01:50:33 2013 (r250130) +++ head/sys/netpfil/ipfw/ip_dummynet.c Wed May 1 04:37:34 2013 (r250131) @@ -618,7 +618,7 @@ fsk_detach(struct dn_fsk *fs, int flags) fs->sched->fp->free_fsk(fs); fs->sched = NULL; if (flags & DN_DELETE_FS) { - bzero(fs, sizeof(fs)); /* safety */ + bzero(fs, sizeof(*fs)); /* safety */ free(fs, M_DUMMYNET); dn_cfg.fsk_count--; } else {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201305010437.r414bZiJ064423>