Commit 19ed9729 authored by Lei Zhang's avatar Lei Zhang Committed by Alexandre Julliard

comdlg32: Avoid double free in PRINTDLG_PaperSizeA/W.

parent 9ea9eaaa
...@@ -497,7 +497,6 @@ static BOOL PRINTDLG_PaperSizeA( ...@@ -497,7 +497,6 @@ static BOOL PRINTDLG_PaperSizeA(
for (i=0;i<NrOfEntries;i++) for (i=0;i<NrOfEntries;i++)
if (Words[i] == PaperSize) if (Words[i] == PaperSize)
break; break;
HeapFree(GetProcessHeap(),0,Words);
if (i == NrOfEntries) { if (i == NrOfEntries) {
FIXME("Papersize %d not found in list?\n",PaperSize); FIXME("Papersize %d not found in list?\n",PaperSize);
goto out; goto out;
...@@ -555,7 +554,6 @@ static BOOL PRINTDLG_PaperSizeW( ...@@ -555,7 +554,6 @@ static BOOL PRINTDLG_PaperSizeW(
for (i=0;i<NrOfEntries;i++) for (i=0;i<NrOfEntries;i++)
if (!lstrcmpW(PaperSize,Names+(64*i))) if (!lstrcmpW(PaperSize,Names+(64*i)))
break; break;
HeapFree(GetProcessHeap(),0,Names);
if (i==NrOfEntries) { if (i==NrOfEntries) {
FIXME("Papersize %s not found in list?\n",debugstr_w(PaperSize)); FIXME("Papersize %s not found in list?\n",debugstr_w(PaperSize));
goto out; goto out;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment