Skip to contentSkip to conversation

Fix NULL derefence in OSS MAUI driver.

PATCH New Dave Jones 1 participant 1 message Sep 1, 2004 Sound

lore
Share & tools
lore

Dave Jones

author
#0 lore raw

PATCH 1/1 Fix NULL derefence in OSS MAUI driver.

Spotted with the source checker from Coverity.com.

sound/oss/maui.c +1 -2
diff -urpN --exclude-from=/home/davej/.exclude bk-linus/sound/oss/maui.c linux-2.6/sound/oss/maui.c
@@ -383,9 +383,8 @@ static int __init probe_maui(struct addr
 		 */
 
 		synth = midi_devs[this_dev]->converter;
-		synth->id = "MAUI";
-
 		if (synth != NULL) {
+			synth->id = "MAUI";
 			orig_load_patch = synth->load_patch;
 			synth->load_patch = &maui_load_patch;
 		} else