diff --git a/programs/winecfg/appdefaults.c b/programs/winecfg/appdefaults.c index caabd06b3d..32319774c6 100644 --- a/programs/winecfg/appdefaults.c +++ b/programs/winecfg/appdefaults.c @@ -291,7 +291,7 @@ static void on_remove_app_click(HWND dialog) static void on_winver_change(HWND dialog) { int selection = SendDlgItemMessage(dialog, IDC_WINVER, CB_GETCURSEL, 0, 0); - VERSION_DESC *ver = getWinVersions(); + const VERSION_DESC *ver = getWinVersions(); if (selection == 0) { diff --git a/programs/winecfg/audio.c b/programs/winecfg/audio.c index e297b0c1b8..4db9379935 100644 --- a/programs/winecfg/audio.c +++ b/programs/winecfg/audio.c @@ -110,7 +110,7 @@ static const char *audioAutoDetect(void) if(!stat("/proc/asound", &buf)) { driversFound[numFound] = "alsa"; - name[numFound] = "Alsa"; + name[numFound] = "ALSA"; numFound++; } @@ -128,7 +128,7 @@ static const char *audioAutoDetect(void) if(!spawnvp(_P_WAIT, "/bin/sh", argv_new)) { driversFound[numFound] = "jack"; - name[numFound] = "jack"; + name[numFound] = "JACK"; numFound++; } diff --git a/programs/winecfg/drivedetect.c b/programs/winecfg/drivedetect.c index de73b7479a..79b5d3602f 100644 --- a/programs/winecfg/drivedetect.c +++ b/programs/winecfg/drivedetect.c @@ -44,13 +44,13 @@ static long working_mask = 0; #ifdef HAVE_MNTENT_H -static DEV_NODES sDeviceNodes[] = { +static const DEV_NODES sDeviceNodes[] = { {"/dev/fd", DRIVE_REMOVABLE}, {"/dev/cdrom", DRIVE_CDROM}, {"",0} }; -static const char *ignored_fstypes[] = { +static const char * const ignored_fstypes[] = { "devpts", "tmpfs", "proc", @@ -61,7 +61,7 @@ static const char *ignored_fstypes[] = { NULL }; -static const char *ignored_mnt_dirs[] = { +static const char * const ignored_mnt_dirs[] = { "/boot", NULL }; @@ -82,7 +82,7 @@ static int try_dev_node(char *dev) static BOOL should_ignore_fstype(char *type) { - const char **s; + const char * const *s; for (s = ignored_fstypes; *s; s++) if (!strcmp(*s, type)) return TRUE; @@ -92,7 +92,7 @@ static BOOL should_ignore_fstype(char *type) static BOOL should_ignore_mnt_dir(char *dir) { - const char **s; + const char * const *s; for (s = ignored_mnt_dirs; *s; s++) if (!strcmp(*s, dir)) return TRUE; @@ -138,7 +138,7 @@ static void report_error(int code) case FSTAB_OPEN: if (gui_mode) { - static const char *s = "Could not open your mountpoint description table.\n\nOpening of /etc/fstab failed: %s"; + static const char s[] = "Could not open your mountpoint description table.\n\nOpening of /etc/fstab failed: %s"; len = snprintf(NULL, 0, s, strerror(errno)); buffer = HeapAlloc(GetProcessHeap(), 0, len + 1); snprintf(buffer, len, s, strerror(errno)); diff --git a/programs/winecfg/properties.c b/programs/winecfg/properties.c index 8cc477f4a6..7373de2eb0 100644 --- a/programs/winecfg/properties.c +++ b/programs/winecfg/properties.c @@ -24,7 +24,7 @@ #include "properties.h" -static VERSION_DESC sWinVersions[] = { +static const VERSION_DESC sWinVersions[] = { {"win2003", "Windows 2003"}, {"winxp", "Windows XP"}, {"win2k", "Windows 2000"}, @@ -39,7 +39,7 @@ static VERSION_DESC sWinVersions[] = { {"", ""} }; -static DLL_DESC sDLLType[] = { +static const DLL_DESC sDLLType[] = { {"oleaut32", DLL_BUILTIN}, {"ole32", DLL_BUILTIN}, {"commdlg", DLL_BUILTIN}, @@ -57,12 +57,12 @@ static DLL_DESC sDLLType[] = { {"", -1} }; -static AUDIO_DRIVER sAudioDrivers[] = { - {"Alsa", "alsa"}, +static const AUDIO_DRIVER sAudioDrivers[] = { + {"ALSA", "alsa"}, {"aRts", "arts"}, {"OSS", "oss"}, - {"Jack", "jack"}, - {"Nas", "nas"}, + {"JACK", "jack"}, + {"NAS", "nas"}, {"Audio IO(Solaris)", "audioio"}, {"Disable sound", ""}, {"", ""} @@ -72,7 +72,7 @@ static AUDIO_DRIVER sAudioDrivers[] = { /***************************************************************************** */ -VERSION_DESC* getWinVersions(void) +const VERSION_DESC* getWinVersions(void) { return sWinVersions; } @@ -80,14 +80,14 @@ VERSION_DESC* getWinVersions(void) /***************************************************************************** */ -DLL_DESC* getDLLDefaults(void) +const DLL_DESC* getDLLDefaults(void) { return sDLLType; } /***************************************************************************** */ -AUDIO_DRIVER* getAudioDrivers(void) +const AUDIO_DRIVER* getAudioDrivers(void) { return sAudioDrivers; } diff --git a/programs/winecfg/properties.h b/programs/winecfg/properties.h index 7851472c49..3d52f326ee 100644 --- a/programs/winecfg/properties.h +++ b/programs/winecfg/properties.h @@ -93,10 +93,10 @@ typedef struct int nType; } DEV_NODES; -VERSION_DESC *getWinVersions(void); -VERSION_DESC *getDOSVersions(void); -DLL_DESC *getDLLDefaults(void); -AUDIO_DRIVER *getAudioDrivers(void); +const VERSION_DESC *getWinVersions(void); +const VERSION_DESC *getDOSVersions(void); +const DLL_DESC *getDLLDefaults(void); +const AUDIO_DRIVER *getAudioDrivers(void); char* getVersionFromDescription(VERSION_DESC *pVer, char *desc); char* getDescriptionFromVersion(VERSION_DESC *pVer, char *ver);