diff options
Diffstat (limited to 'src/Common')
-rw-r--r-- | src/Common/Cmdline.c | 2 | ||||
-rw-r--r-- | src/Common/Dlgcode.c | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/Common/Cmdline.c b/src/Common/Cmdline.c index cf3903d6..35507c2b 100644 --- a/src/Common/Cmdline.c +++ b/src/Common/Cmdline.c @@ -55,6 +55,8 @@ BOOL CALLBACK CommandHelpDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM }
SetWindowText (GetDlgItem (hwndDlg, IDC_COMMANDHELP_TEXT), (char*) tmp);
+
+ TCfree(tmp);
return 1;
}
diff --git a/src/Common/Dlgcode.c b/src/Common/Dlgcode.c index f645fdec..084e93d5 100644 --- a/src/Common/Dlgcode.c +++ b/src/Common/Dlgcode.c @@ -6743,7 +6743,11 @@ __int64 FindStringInFile (const char *filePath, const char* str, int strLen) || buffer == NULL
|| strLen > bufSize
|| strLen < 1)
+ {
+ if (buffer)
+ free (buffer);
return -1;
+ }
src = CreateFile (filePath, GENERIC_READ, FILE_SHARE_READ | FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, NULL);
|