From b05173486a12adaaa14d206da4c8f8aa3c9871c6 Mon Sep 17 00:00:00 2001 From: Dmitry Timoshkov Date: Thu, 14 Dec 2006 22:46:12 +0800 Subject: [PATCH] wineoss: Make some data const. --- dlls/winmm/wineoss/midi.c | 4 ++-- dlls/winmm/wineoss/midipatch.c | 6 ++---- dlls/winmm/wineoss/mixer.c | 4 ++-- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/dlls/winmm/wineoss/midi.c b/dlls/winmm/wineoss/midi.c index 6b9cdf8c72b..ffa7d86d7a4 100644 --- a/dlls/winmm/wineoss/midi.c +++ b/dlls/winmm/wineoss/midi.c @@ -1000,8 +1000,8 @@ typedef struct sFMextra { */ } sFMextra; -extern unsigned char midiFMInstrumentPatches[16 * 128]; -extern unsigned char midiFMDrumsPatches [16 * 128]; +extern const unsigned char midiFMInstrumentPatches[16 * 128]; +extern const unsigned char midiFMDrumsPatches [16 * 128]; /************************************************************************** * modFMLoad [internal] diff --git a/dlls/winmm/wineoss/midipatch.c b/dlls/winmm/wineoss/midipatch.c index e991e04a1f6..1180c6f20cd 100644 --- a/dlls/winmm/wineoss/midipatch.c +++ b/dlls/winmm/wineoss/midipatch.c @@ -26,7 +26,7 @@ #define NOT_DEFINED 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -unsigned char midiFMInstrumentPatches[128 * 16] = { +const unsigned char midiFMInstrumentPatches[128 * 16] = { /* 0 Acoustic Grand Piano */ 0x21, 0x11, 0x4c, 0x00, 0xf1, 0xf2, 0x63, 0x72, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, /* 1 Bright Acoustic Piano */ 0x01, 0x11, 0x4f, 0x00, 0xf1, 0xd2, 0x53, 0x74, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, /* 2 Electric Grand Piano */ 0x01, 0x01, 0x4f, 0x04, 0xf1, 0xd2, 0x50, 0x7c, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -157,7 +157,7 @@ unsigned char midiFMInstrumentPatches[128 * 16] = { /* 127 Gunshot */ 0x0c, 0x50, 0x00, 0x21, 0xf8, 0x09, 0xb6, 0x04, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, }; -unsigned char midiFMDrumsPatches[16 * 128] = { +const unsigned char midiFMDrumsPatches[16 * 128] = { /* 1 Not defined */ NOT_DEFINED /* 2 Not defined */ NOT_DEFINED /* 3 Not defined */ NOT_DEFINED @@ -287,5 +287,3 @@ unsigned char midiFMDrumsPatches[16 * 128] = { /* 127 Not defined */ NOT_DEFINED /* 128 Not defined */ NOT_DEFINED }; - - diff --git a/dlls/winmm/wineoss/mixer.c b/dlls/winmm/wineoss/mixer.c index bce0628855c..a28305b3262 100644 --- a/dlls/winmm/wineoss/mixer.c +++ b/dlls/winmm/wineoss/mixer.c @@ -79,8 +79,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(mixer); /* FIXME: the two following string arrays should be moved to a resource file in a string table */ /* if it's done, better use a struct to hold labels, name, and muted channel volume cache */ -static const char* MIX_Labels[SOUND_MIXER_NRDEVICES] = SOUND_DEVICE_LABELS; -static const char* MIX_Names [SOUND_MIXER_NRDEVICES] = SOUND_DEVICE_NAMES; +static const char * const MIX_Labels[SOUND_MIXER_NRDEVICES] = SOUND_DEVICE_LABELS; +static const char * const MIX_Names [SOUND_MIXER_NRDEVICES] = SOUND_DEVICE_NAMES; struct mixerCtrl {