Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 24 Sep 2006 10:07:47 -0700
From:      David Wolfskill <david@catwhisker.org>
To:        current@freebsd.org
Cc:        netchild@freebsd.org
Subject:   [PATCH] Problem with src/sys/dev/sound/pcm/mixer.c rev. 1.50
Message-ID:  <20060924170747.GM698@bunrab.catwhisker.org>

next in thread | raw e-mail | index | archive | help

--Jxom2kD0UhQdW59L
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

During today's CURRENT build, I encountered:

>>> stage 3.2: building everything
=2E..
cc -c -O -pipe  -std=3Dc99 -g -Wall -Wredundant-decls -Wnested-externs -Wst=
rict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual =
 -Wundef -fformat-extensions -nostdinc -I-  -I. -I/usr/src/sys -I/usr/src/s=
ys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.=
h -fno-common -finline-limit=3D8000 --param inline-unit-growth=3D100 --para=
m large-function-growth=3D1000  -mno-align-long-strings -mpreferred-stack-b=
oundary=3D2  -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestandin=
g -Werror  /usr/src/sys/dev/sound/pcm/feeder_volume.c
cc -c -O -pipe  -std=3Dc99 -g -Wall -Wredundant-decls -Wnested-externs -Wst=
rict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual =
 -Wundef -fformat-extensions -nostdinc -I-  -I. -I/usr/src/sys -I/usr/src/s=
ys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.=
h -fno-common -finline-limit=3D8000 --param inline-unit-growth=3D100 --para=
m large-function-growth=3D1000  -mno-align-long-strings -mpreferred-stack-b=
oundary=3D2  -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestandin=
g -Werror  /usr/src/sys/dev/sound/pcm/mixer.c
/usr/src/sys/dev/sound/pcm/mixer.c: In function `mixer_oss_mixerinfo':
/usr/src/sys/dev/sound/pcm/mixer.c:761: warning: 'd' might be used uninitia=
lized in this function
*** Error code 1

Stop in /common/S4/obj/usr/src/sys/LAPTOP_30W.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.


This was with rev. 1.50 of src/sys/dev/sound/pcm/mixer.c.

I'm not sure the following patch is correct, but making this change did
allow the kernel to build, install, and boot, which seemed an improvement
at the time:

Index: sys/dev/sound/pcm/mixer.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /cvs/freebsd/src/sys/dev/sound/pcm/mixer.c,v
retrieving revision 1.50
diff -u -r1.50 mixer.c
--- sys/dev/sound/pcm/mixer.c	23 Sep 2006 20:45:47 -0000	1.50
+++ sys/dev/sound/pcm/mixer.c	24 Sep 2006 16:38:54 -0000
@@ -770,6 +770,7 @@
 	if ((mi->dev =3D=3D -1) && (i_dev->si_devsw !=3D &mixer_cdevsw))
 		return EINVAL;
=20
+	d =3D NULL;
 	m =3D NULL;
 	t_cdev =3D NULL;
 	nmix =3D 0;


Peace,
david
--=20
David H. Wolfskill				david@catwhisker.org
Believe SORBS at your own risk: 63.193.123.122 has been static since Aug 19=
99.

See http://www.catwhisker.org/~david/publickey.gpg for my public key.

--Jxom2kD0UhQdW59L
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (FreeBSD)

iEYEARECAAYFAkUWu2IACgkQmprOCmdXAD1e3wCeJZZ0e1Ppt9CahfiHYd9eYyzB
g4UAn1g4C3fRBNTYNHebbkNDCbTlMal9
=ykpH
-----END PGP SIGNATURE-----

--Jxom2kD0UhQdW59L--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060924170747.GM698>