[macro] fix use of WINPR_DEPRECATED

This commit is contained in:
akallabeth
2025-02-17 11:04:03 +01:00
parent 84fbfa17e2
commit e259eee0df
13 changed files with 82 additions and 84 deletions

View File

@@ -240,7 +240,7 @@ extern "C"
WINPR_API BOOL ArrayList_Contains(wArrayList* arrayList, const void* obj);
#if defined(WITH_WINPR_DEPRECATED)
WINPR_API WINPR_DEPRECATED(int ArrayList_Add(wArrayList* arrayList, const void* obj));
WINPR_DEPRECATED(WINPR_API int ArrayList_Add(wArrayList* arrayList, const void* obj));
#endif
WINPR_API BOOL ArrayList_Append(wArrayList* arrayList, const void* obj);
@@ -628,7 +628,7 @@ extern "C"
WINPR_API size_t HashTable_Count(wHashTable* table);
#if defined(WITH_WINPR_DEPRECATED)
WINPR_API WINPR_DEPRECATED(int HashTable_Add(wHashTable* table, const void* key,
WINPR_DEPRECATED(WINPR_API int HashTable_Add(wHashTable* table, const void* key,
const void* value));
#endif

View File

@@ -264,12 +264,12 @@ extern "C"
WINPR_API void winpr_Cipher_Free(WINPR_CIPHER_CTX* ctx);
WINPR_ATTR_MALLOC(winpr_Cipher_Free, 1)
WINPR_API WINPR_DEPRECATED_VAR("[since 3.10.0] use winpr_Cipher_NewEx",
WINPR_CIPHER_CTX* winpr_Cipher_New(WINPR_CIPHER_TYPE cipher,
WINPR_CRYPTO_OPERATION op,
const void* key,
const void* iv));
WINPR_DEPRECATED_VAR("[since 3.10.0] use winpr_Cipher_NewEx",
WINPR_ATTR_MALLOC(winpr_Cipher_Free, 1)
WINPR_API WINPR_CIPHER_CTX* winpr_Cipher_New(WINPR_CIPHER_TYPE cipher,
WINPR_CRYPTO_OPERATION op,
const void* key,
const void* iv));
/** @brief Create a new \b WINPR_CIPHER_CTX
*

View File

@@ -1275,12 +1275,12 @@ extern "C"
#define Stream_GetPointerAs(_s, _p) _p = Stream_PointerAs(_s, __typeof(_p))
#if defined(WITH_WINPR_DEPRECATED)
WINPR_API WINPR_DEPRECATED_VAR("Use Stream_SetPosition instead",
BOOL Stream_SetPointer(wStream* _s, BYTE* _p));
WINPR_API WINPR_DEPRECATED_VAR("Use Stream_New(buffer, capacity) instead",
BOOL Stream_SetBuffer(wStream* _s, BYTE* _b));
WINPR_API WINPR_DEPRECATED_VAR("Use Stream_New(buffer, capacity) instead",
void Stream_SetCapacity(wStream* _s, size_t capacity));
WINPR_DEPRECATED_VAR("Use Stream_SetPosition instead",
WINPR_API BOOL Stream_SetPointer(wStream* _s, BYTE* _p));
WINPR_DEPRECATED_VAR("Use Stream_New(buffer, capacity) instead",
WINPR_API BOOL Stream_SetBuffer(wStream* _s, BYTE* _b));
WINPR_DEPRECATED_VAR("Use Stream_New(buffer, capacity) instead",
WINPR_API void Stream_SetCapacity(wStream* _s, size_t capacity));
#endif
static INLINE size_t Stream_Length(const wStream* _s)

View File

@@ -185,13 +185,13 @@ extern "C"
/* Unicode Conversion */
#if defined(WITH_WINPR_DEPRECATED)
WINPR_API WINPR_DEPRECATED_VAR("Use ConvertUtf8ToWChar instead",
int MultiByteToWideChar(UINT CodePage, DWORD dwFlags,
WINPR_DEPRECATED_VAR("Use ConvertUtf8ToWChar instead",
WINPR_API int MultiByteToWideChar(UINT CodePage, DWORD dwFlags,
LPCSTR lpMultiByteStr, int cbMultiByte,
LPWSTR lpWideCharStr, int cchWideChar));
WINPR_API WINPR_DEPRECATED_VAR("Use ConvertWCharToUtf8 instead",
int WideCharToMultiByte(UINT CodePage, DWORD dwFlags,
WINPR_DEPRECATED_VAR("Use ConvertWCharToUtf8 instead",
WINPR_API int WideCharToMultiByte(UINT CodePage, DWORD dwFlags,
LPCWSTR lpWideCharStr, int cchWideChar,
LPSTR lpMultiByteStr, int cbMultiByte,
LPCSTR lpDefaultChar,
@@ -406,13 +406,13 @@ extern "C"
WINPR_API const WCHAR* InitializeConstWCharFromUtf8(const char* str, WCHAR* buffer, size_t len);
#if defined(WITH_WINPR_DEPRECATED)
WINPR_API WINPR_DEPRECATED_VAR("Use ConvertUtf8ToWChar functions instead",
int ConvertToUnicode(UINT CodePage, DWORD dwFlags,
WINPR_DEPRECATED_VAR("Use ConvertUtf8ToWChar functions instead",
WINPR_API int ConvertToUnicode(UINT CodePage, DWORD dwFlags,
LPCSTR lpMultiByteStr, int cbMultiByte,
LPWSTR* lpWideCharStr, int cchWideChar));
WINPR_API WINPR_DEPRECATED_VAR("Use ConvertWCharToUtf8 functions instead",
int ConvertFromUnicode(UINT CodePage, DWORD dwFlags,
WINPR_DEPRECATED_VAR("Use ConvertWCharToUtf8 functions instead",
WINPR_API int ConvertFromUnicode(UINT CodePage, DWORD dwFlags,
LPCWSTR lpWideCharStr, int cchWideChar,
LPSTR* lpMultiByteStr, int cbMultiByte,
LPCSTR lpDefaultChar,

View File

@@ -221,9 +221,9 @@ extern "C"
#if defined(WITH_WINPR_DEPRECATED)
/** Deprecated */
WINPR_API WINPR_DEPRECATED(BOOL WLog_Init(void));
WINPR_DEPRECATED(WINPR_API BOOL WLog_Init(void));
/** Deprecated */
WINPR_API WINPR_DEPRECATED(BOOL WLog_Uninit(void));
WINPR_DEPRECATED(WINPR_API BOOL WLog_Uninit(void));
#endif
typedef BOOL (*wLogCallbackMessage_t)(const wLogMessage* msg);