projects
/
platform
/
upstream
/
freerdp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7b740f1
)
channels/drive: Fix leak found by covscan
author
Ondrej Holy
<oholy@redhat.com>
Fri, 17 Aug 2018 10:43:49 +0000
(12:43 +0200)
committer
Ondrej Holy
<oholy@redhat.com>
Wed, 22 Aug 2018 11:35:43 +0000
(13:35 +0200)
leaked_storage: Variable "outStr" going out of scope leaks the storage it points to.
channels/drive/client/drive_main.c
patch
|
blob
|
history
diff --git
a/channels/drive/client/drive_main.c
b/channels/drive/client/drive_main.c
index
10ebbbd
..
d6bfd6d
100644
(file)
--- a/
channels/drive/client/drive_main.c
+++ b/
channels/drive/client/drive_main.c
@@
-527,6
+527,7
@@
static UINT drive_process_irp_query_volume_information(DRIVE_DEVICE* drive,
if (!Stream_EnsureRemainingCapacity(output, 12 + length))
{
+ free(outStr);
WLog_ERR(TAG, "Stream_EnsureRemainingCapacity failed!");
return CHANNEL_RC_NO_MEMORY;
}