diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/amvideo.cpp b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/amvideo.cpp index 42fe446de..25383891d 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/amvideo.cpp +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/amvideo.cpp @@ -23,8 +23,8 @@ const DWORD bits888[] = {0xFF0000,0x00FF00,0x0000FF}; const struct { const GUID *pSubtype; WORD BitCount; - CHAR *pName; - WCHAR *wszName; + const CHAR *pName; + const WCHAR *wszName; } BitCountMap[] = { &MEDIASUBTYPE_RGB1, 1, "RGB Monochrome", L"RGB Monochrome", &MEDIASUBTYPE_RGB4, 4, "RGB VGA", L"RGB VGA", &MEDIASUBTYPE_RGB8, 8, "RGB 8", L"RGB 8", @@ -173,12 +173,12 @@ int LocateSubtype(const GUID *pSubtype) -STDAPI_(WCHAR *) GetSubtypeNameW(const GUID *pSubtype) +STDAPI_(const WCHAR *) GetSubtypeNameW(const GUID *pSubtype) { return BitCountMap[LocateSubtype(pSubtype)].wszName; } -STDAPI_(CHAR *) GetSubtypeNameA(const GUID *pSubtype) +STDAPI_(const CHAR *) GetSubtypeNameA(const GUID *pSubtype) { return BitCountMap[LocateSubtype(pSubtype)].pName; } @@ -190,7 +190,7 @@ STDAPI_(CHAR *) GetSubtypeNameA(const GUID *pSubtype) // this is here for people that linked to it directly; most people // would use the header file that picks the A or W version. -STDAPI_(CHAR *) GetSubtypeName(const GUID *pSubtype) +STDAPI_(const CHAR *) GetSubtypeName(const GUID *pSubtype) { return GetSubtypeNameA(pSubtype); } diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.cpp b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.cpp index b12ccbd37..dae0f1fa0 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.cpp +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.cpp @@ -15,7 +15,7 @@ // buffer in the property page class and use it for all string loading. It // cannot be static as multiple property pages may be active simultaneously -LPTSTR WINAPI StringFromResource(__out_ecount(STR_MAX_LENGTH) LPTSTR pBuffer, int iResourceID) +LPCTSTR WINAPI StringFromResource(__out_ecount(STR_MAX_LENGTH) LPTSTR pBuffer, int iResourceID) { if (LoadString(g_hInst,iResourceID,pBuffer,STR_MAX_LENGTH) == 0) { return TEXT(""); diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.h b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.h index 62770bd2d..5244ca051 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.h +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/videoctl.h @@ -17,7 +17,7 @@ // resource ID of a dialog box and returns the size of it in screen pixels #define STR_MAX_LENGTH 256 -LPTSTR WINAPI StringFromResource(__out_ecount(STR_MAX_LENGTH) LPTSTR pBuffer, int iResourceID); +LPCTSTR WINAPI StringFromResource(__out_ecount(STR_MAX_LENGTH) LPTSTR pBuffer, int iResourceID); #ifdef UNICODE #define WideStringFromResource StringFromResource diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.cpp b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.cpp index 78e047209..31763bf71 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.cpp +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.cpp @@ -86,7 +86,7 @@ bool g_fAutoRefreshLevels = false; LPCTSTR pBaseKey = TEXT("SOFTWARE\\Microsoft\\DirectShow\\Debug"); LPCTSTR pGlobalKey = TEXT("GLOBAL"); -static CHAR *pUnknownName = "UNKNOWN"; +static const CHAR *pUnknownName = "UNKNOWN"; LPCTSTR TimeoutName = TEXT("TIMEOUT"); @@ -1086,7 +1086,7 @@ void WINAPI DbgSetWaitTimeout(DWORD dwTimeout) CGuidNameList GuidNames; int g_cGuidNames = sizeof(g_GuidNames) / sizeof(g_GuidNames[0]); - char *CGuidNameList::operator [] (const GUID &guid) + const char *CGuidNameList::operator [] (const GUID &guid) { for (int i = 0; i < g_cGuidNames; i++) { if (g_GuidNames[i].guid == guid) { diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.h b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.h index d4c69dbb0..7d2518fe0 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.h +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxdebug.h @@ -254,13 +254,13 @@ typedef struct tag_ObjectDesc { // Returns the name defined in uuids.h as a string typedef struct { - CHAR *szName; + const CHAR *szName; GUID guid; } GUID_STRING_ENTRY; class CGuidNameList { public: - CHAR *operator [] (const GUID& guid); + const CHAR *operator [] (const GUID& guid); }; extern CGuidNameList GuidNames; diff --git a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxutil.h b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxutil.h index 0f171394e..36777baf6 100644 --- a/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxutil.h +++ b/Backends/System/Windows/Libraries/DirectShow/BaseClasses/wxutil.h @@ -408,8 +408,8 @@ STDAPI_(WORD) GetBitCount(const GUID *pSubtype); // // STDAPI_(/* T */ CHAR *) GetSubtypeName(const GUID *pSubtype); -STDAPI_(CHAR *) GetSubtypeNameA(const GUID *pSubtype); -STDAPI_(WCHAR *) GetSubtypeNameW(const GUID *pSubtype); +STDAPI_(const CHAR *) GetSubtypeNameA(const GUID *pSubtype); +STDAPI_(const WCHAR *) GetSubtypeNameW(const GUID *pSubtype); #ifdef UNICODE #define GetSubtypeName GetSubtypeNameW