ALSA: hda: fix nid variable warning
authorMatthew Ranostay <mranostay@embeddedalley.com>
Mon, 13 Oct 2008 17:22:45 +0000 (13:22 -0400)
committerTakashi Iwai <tiwai@suse.de>
Tue, 14 Oct 2008 05:42:55 +0000 (07:42 +0200)
Fixed compiler warning with possible uninitialized variable 'nid'.

  CC [M]  /home/mranostay/git/alsa-driver/pci/hda/patch_sigmatel.o
/home/mranostay/git/alsa-driver/pci/hda/../../alsa-kernel/pci/hda/patch_sigmatel.c: In function
‘stac92xx_parse_auto_config’:
/home/mranostay/git/alsa-driver/pci/hda/../../alsa-kernel/pci/hda/patch_sigmatel.c:2815: warning: ‘nid’ may be used
uninitialized in this function

Signed-off-by: Matthew Ranostay <mranostay@embeddedalley.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/patch_sigmatel.c

index c5906551311895285782942e49a92ca43c608f06..a2ac7205d45de81706ef520e2c9dca69f5ce503d 100644 (file)
@@ -2816,7 +2816,7 @@ static int stac92xx_auto_create_multi_out_ctls(struct hda_codec *codec,
        static const char *chname[4] = {
                "Front", "Surround", NULL /*CLFE*/, "Side"
        };
-       hda_nid_t nid;
+       hda_nid_t nid = 0;
        int i, err;
 
        struct sigmatel_spec *spec = codec->spec;