889964baef8ad449b2af9dd570309f0d7a0ca06c
[openwrt.git] / target / linux / generic-2.4 / patches / 222-sound.patch
1 Index: linux-2.4.35.4/drivers/sound/sound_core.c
2 ===================================================================
3 --- linux-2.4.35.4.orig/drivers/sound/sound_core.c 2007-12-15 05:19:38.946640480 +0100
4 +++ linux-2.4.35.4/drivers/sound/sound_core.c 2007-12-15 05:20:01.199908622 +0100
5 @@ -174,9 +174,9 @@
6 }
7
8 if (r == low)
9 - sprintf (name_buf, "%s", name);
10 + snprintf (name_buf, sizeof(name_buf), "%s", name);
11 else
12 - sprintf (name_buf, "%s%d", name, (r - low) / SOUND_STEP);
13 + snprintf (name_buf, sizeof(name_buf), "%s%d", name, (r - low) / SOUND_STEP);
14 s->de = devfs_register (devfs_handle, name_buf,
15 DEVFS_FL_NONE, SOUND_MAJOR, s->unit_minor,
16 S_IFCHR | mode, fops, NULL);
17 @@ -507,9 +507,9 @@
18 * ALSA toplevel modules for soundcards, thus we need
19 * load them at first. [Jaroslav Kysela <perex@jcu.cz>]
20 */
21 - sprintf(mod, "sound-slot-%i", unit>>4);
22 + snprintf(mod, sizeof(mod), "sound-slot-%i", unit>>4);
23 request_module(mod);
24 - sprintf(mod, "sound-service-%i-%i", unit>>4, chain);
25 + snprintf(mod, sizeof(mod), "sound-service-%i-%i", unit>>4, chain);
26 request_module(mod);
27 spin_lock(&sound_loader_lock);
28 s = __look_for_unit(chain, unit);
This page took 0.039352 seconds and 3 git commands to generate.