[warnings] fix cppcoreguidelines-init-variables
This commit is contained in:
parent
6d994feef6
commit
3b1c1e0af1
@ -32,7 +32,7 @@ FREERDP_LOCAL void gdi_bitmap_free_ex(gdiBitmap* gdi_bmp);
|
||||
|
||||
static INLINE BYTE* gdi_get_bitmap_pointer(HGDI_DC hdcBmp, INT32 x, INT32 y)
|
||||
{
|
||||
BYTE* p;
|
||||
BYTE* p = NULL;
|
||||
HGDI_BITMAP hBmp = (HGDI_BITMAP)hdcBmp->selectedObject;
|
||||
|
||||
if ((x >= 0) && (y >= 0) && (x < hBmp->width) && (y < hBmp->height))
|
||||
@ -59,7 +59,7 @@ static INLINE BYTE* gdi_get_bitmap_pointer(HGDI_DC hdcBmp, INT32 x, INT32 y)
|
||||
*/
|
||||
static INLINE BYTE* gdi_get_brush_pointer(HGDI_DC hdcBrush, UINT32 x, UINT32 y)
|
||||
{
|
||||
BYTE* p;
|
||||
BYTE* p = NULL;
|
||||
UINT32 brushStyle = gdi_GetBrushStyle(hdcBrush);
|
||||
|
||||
switch (brushStyle)
|
||||
|
@ -228,7 +228,7 @@ static INLINE BYTE CLIP(INT64 X)
|
||||
static INLINE BYTE CONDITIONAL_CLIP(INT32 in, BYTE original)
|
||||
{
|
||||
BYTE out = CLIP(in);
|
||||
BYTE diff;
|
||||
BYTE diff = 0;
|
||||
if (out > original)
|
||||
diff = out - original;
|
||||
else
|
||||
|
@ -131,7 +131,7 @@ extern "C"
|
||||
|
||||
static INLINE void Stream_Rewind(wStream* s, size_t _offset)
|
||||
{
|
||||
size_t cur;
|
||||
size_t cur = 0;
|
||||
WINPR_ASSERT(s);
|
||||
WINPR_ASSERT(s->buffer <= s->pointer);
|
||||
cur = WINPR_STREAM_CAST(size_t, s->pointer - s->buffer);
|
||||
|
@ -143,7 +143,7 @@ static INLINE void WINPR_HANDLE_SET_TYPE_AND_MODE(void* _handle, ULONG _type, UL
|
||||
|
||||
static INLINE BOOL winpr_Handle_GetInfo(HANDLE handle, ULONG* pType, WINPR_HANDLE** pObject)
|
||||
{
|
||||
WINPR_HANDLE* wHandle;
|
||||
WINPR_HANDLE* wHandle = NULL;
|
||||
|
||||
if (handle == NULL)
|
||||
return FALSE;
|
||||
@ -165,8 +165,8 @@ static INLINE BOOL winpr_Handle_GetInfo(HANDLE handle, ULONG* pType, WINPR_HANDL
|
||||
|
||||
static INLINE int winpr_Handle_getFd(HANDLE handle)
|
||||
{
|
||||
WINPR_HANDLE* hdl;
|
||||
ULONG type;
|
||||
WINPR_HANDLE* hdl = NULL;
|
||||
ULONG type = 0;
|
||||
|
||||
if (!winpr_Handle_GetInfo(handle, &type, &hdl))
|
||||
return -1;
|
||||
@ -179,8 +179,8 @@ static INLINE int winpr_Handle_getFd(HANDLE handle)
|
||||
|
||||
static INLINE DWORD winpr_Handle_cleanup(HANDLE handle)
|
||||
{
|
||||
WINPR_HANDLE* hdl;
|
||||
ULONG type;
|
||||
WINPR_HANDLE* hdl = NULL;
|
||||
ULONG type = 0;
|
||||
|
||||
if (!winpr_Handle_GetInfo(handle, &type, &hdl))
|
||||
return WAIT_FAILED;
|
||||
|
Loading…
Reference in New Issue
Block a user