diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 85c2fd1d..d154ea20 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -2101,6 +2101,7 @@ Matthias Schwarzott for suggesting to move the "all" target in plugin Makefiles before the "Implicit rules", so that a plain "make" will compile everything for adding DESTDIR and PREFIX handling to the Makefile + for fixing some compiler warnings with gcc-4.2.0 Martin Ostermann for fixing processing the PDCDescriptor in 'libsi' on big endian systems diff --git a/HISTORY b/HISTORY index 45037d50..982598f7 100644 --- a/HISTORY +++ b/HISTORY @@ -5390,3 +5390,4 @@ Video Disk Recorder Revision History - Fixed detecting whether a particular locale is actually supported. - Added a note about LANG having to be set to a valid locale in INSTALL (suggested by Matthias Fechner). +- Fixed some compiler warnings with gcc-4.2.0 (thanks to Matthias Schwarzott). diff --git a/i18n.c b/i18n.c index b475a3b3..cf0798fd 100644 --- a/i18n.c +++ b/i18n.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: i18n.c 1.315 2007/08/24 13:08:04 kls Exp $ + * $Id: i18n.c 1.316 2007/08/24 13:15:48 kls Exp $ * * */ @@ -62,7 +62,7 @@ const char *LanguageCodeList[] = { NULL }; -static char *I18nLocaleDir = LOCDIR; +static const char *I18nLocaleDir = LOCDIR; static cStringList LanguageLocales; static cStringList LanguageNames; diff --git a/keys.h b/keys.h index da4b7a45..2adcad8a 100644 --- a/keys.h +++ b/keys.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: keys.h 1.12 2007/08/04 14:40:23 kls Exp $ + * $Id: keys.h 1.13 2007/08/24 13:15:48 kls Exp $ */ #ifndef __KEYS_H @@ -82,7 +82,7 @@ enum eKeys { // "Up" and "Down" must be the first two keys! struct tKey { eKeys type; - char *name; + const char *name; }; class cKey : public cListObject { diff --git a/menu.c b/menu.c index 4d94b610..444fd750 100644 --- a/menu.c +++ b/menu.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: menu.c 1.460 2007/08/18 09:03:05 kls Exp $ + * $Id: menu.c 1.461 2007/08/24 13:15:48 kls Exp $ */ #include "menu.h" @@ -1040,7 +1040,7 @@ int cMenuScheduleItem::Compare(const cListObject &ListObject) const return r; } -static char *TimerMatchChars = " tT"; +static const char *TimerMatchChars = " tT"; bool cMenuScheduleItem::Update(bool Force) { diff --git a/rcu.c b/rcu.c index d81c0b6a..34b43877 100644 --- a/rcu.c +++ b/rcu.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: rcu.c 1.15 2006/12/02 11:12:28 kls Exp $ + * $Id: rcu.c 1.16 2007/08/24 13:15:48 kls Exp $ */ #include "rcu.h" @@ -257,7 +257,7 @@ void cRcuRemote::SetNumber(int n, bool Hex) data = m; } -void cRcuRemote::SetString(char *s) +void cRcuRemote::SetString(const char *s) { const char *chars = mode == modeH ? "0123456789ABCDEF" : "0123456789-EHLP "; int n = 0; diff --git a/rcu.h b/rcu.h index 7592dc2b..8824f660 100644 --- a/rcu.h +++ b/rcu.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: rcu.h 1.6 2005/12/31 15:09:25 kls Exp $ + * $Id: rcu.h 1.7 2007/08/24 13:15:48 kls Exp $ */ #ifndef __RCU_H @@ -31,7 +31,7 @@ private: void SetMode(unsigned char Mode); void SetNumber(int n, bool Hex = false); void SetPoints(unsigned char Dp, bool On); - void SetString(char *s); + void SetString(const char *s); bool DetectCode(unsigned char *Code); virtual void Action(void); virtual void ChannelSwitch(const cDevice *Device, int ChannelNumber); diff --git a/thread.c b/thread.c index 4eb64f1e..a0647d0e 100644 --- a/thread.c +++ b/thread.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: thread.c 1.61 2007/06/17 12:43:40 kls Exp $ + * $Id: thread.c 1.62 2007/08/24 13:15:48 kls Exp $ */ #include "thread.h" @@ -416,7 +416,7 @@ bool cPipe::Open(const char *Command, const char *Mode) return false; } - char *mode = "w"; + const char *mode = "w"; int iopipe = 0; if (pid > 0) { // parent process