GNU bug report logs - #8278
possibly-uninitialized variable in sound.c's wav_play

Previous Next

Package: emacs;

Reported by: Paul Eggert <eggert <at> cs.ucla.edu>

Date: Fri, 18 Mar 2011 06:43:01 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: bug-gnu-emacs <at> gnu.org
Subject: possibly-uninitialized variable in sound.c's wav_play
Date: Thu, 17 Mar 2011 23:41:08 -0700
In the Emacs trunk, src/sound.c's wav_play function can
use an uninitialized variable 'nbytes' if it reads
a file whose header->data_length field is zero.

I plan to work around this by initializing nbytes to 0.

(This problem was discovered by using gcc -Wuninitialized.)




This bug report was last modified 14 years and 122 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.