summaryrefslogtreecommitdiff
path: root/tipper/popwin.cpp
diff options
context:
space:
mode:
authorghazan <ghazan@4f64403b-2f21-0410-a795-97e2b3489a10>2008-02-05 19:34:06 +0000
committerghazan <ghazan@4f64403b-2f21-0410-a795-97e2b3489a10>2008-02-05 19:34:06 +0000
commit71780cf8882b0b9f1914790910a150b5bfd6dfe2 (patch)
treea84fe84422f70b1de5032bdb32698a143f903192 /tipper/popwin.cpp
parent5f5b8d7af4078b9eafbc162ba22806606a369fac (diff)
fix for a memory allocation problem
git-svn-id: https://server.scottellis.com.au/svn/mim_plugs@391 4f64403b-2f21-0410-a795-97e2b3489a10
Diffstat (limited to 'tipper/popwin.cpp')
-rw-r--r--tipper/popwin.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/tipper/popwin.cpp b/tipper/popwin.cpp
index 59783ba..e241464 100644
--- a/tipper/popwin.cpp
+++ b/tipper/popwin.cpp
@@ -689,8 +689,10 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
free(pwd->rows[pwd->row_count].swzLabel);
free(pwd->rows[pwd->row_count].swzValue);
- if(pwd->row_count == 0)
+ if(pwd->row_count == 0) {
free(pwd->rows);
+ pwd->rows = NULL;
+ }
}
SendMessage(hwnd, PUM_GETHEIGHT, 0, 0); // calculate window height