mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-15 00:44:19 +09:00
[clang,warnings] fix Wjump-misses-init
This commit is contained in:
@@ -1032,17 +1032,21 @@ static BOOL pf_channel_rdpdr_rewrite_device_list_to(wStream* s, UINT32 fromVersi
|
||||
wStream* clone = Stream_New(NULL, cap);
|
||||
if (!clone)
|
||||
goto fail;
|
||||
|
||||
{
|
||||
const size_t pos = Stream_GetPosition(s);
|
||||
Stream_Copy(s, clone, cap);
|
||||
Stream_SealLength(clone);
|
||||
|
||||
Stream_SetPosition(clone, 0);
|
||||
Stream_SetPosition(s, pos);
|
||||
}
|
||||
|
||||
/* Skip device count */
|
||||
if (!Stream_SafeSeek(s, 4))
|
||||
goto fail;
|
||||
|
||||
{
|
||||
UINT32 count = 0;
|
||||
if (Stream_GetRemainingLength(clone) < 4)
|
||||
goto fail;
|
||||
@@ -1094,6 +1098,7 @@ static BOOL pf_channel_rdpdr_rewrite_device_list_to(wStream* s, UINT32 fromVersi
|
||||
Stream_Write(s, device.DeviceData, device.DeviceDataLength);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Stream_SealLength(s);
|
||||
rc = TRUE;
|
||||
|
||||
Reference in New Issue
Block a user