Displaying 1 result from an estimated 1 matches for "lpdevmodea".
2008 Apr 22
1
HeapAlloc vs. malloc. How does HeapAlloc work?
...?? include_defs[num_include_def].value = val;
??? include_defs[num_include_def].vector = NULL;
??? include_defs[num_include_def].nrofentries = 0;
Nobody is checking NULL value of include_defs and later there is strcpy() with HeapAlloc as parameter.
In dlls/winspool.drv/info.c function 'static LPDEVMODEA DEVMODEdupWtoA(HANDLE heap, const DEVMODEW *dmW)' line 1709
???? if (pName) {
???????? len = MultiByteToWideChar(CP_ACP, 0, pName, -1, NULL, 0);
??????? nameW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR));
???????? MultiByteToWideChar(CP_ACP, 0, pName, -1, nameW, len);
???? }
Again no...