Move variable declaration at the top of the function

Remove unneeded affectation of hProcessHeap (already initialized in DllMain)

svn path=/trunk/; revision=16285
This commit is contained in:
Hervé Poussineau 2005-06-26 12:51:17 +00:00
parent 489bda971f
commit daae3048fd

View file

@ -936,14 +936,14 @@ STDCALL
GetCommConfig(HANDLE hCommDev, LPCOMMCONFIG lpCC, LPDWORD lpdwSize) GetCommConfig(HANDLE hCommDev, LPCOMMCONFIG lpCC, LPDWORD lpdwSize)
{ {
BOOL ReturnValue = FALSE; BOOL ReturnValue = FALSE;
LPCOMMPROP lpComPort;
DPRINT("GetCommConfig(%d, %p, %p)\n", hCommDev, lpCC, lpdwSize); DPRINT("GetCommConfig(%d, %p, %p)\n", hCommDev, lpCC, lpdwSize);
hProcessHeap = GetProcessHeap(); lpComPort = RtlAllocateHeap( hProcessHeap,
LPCOMMPROP lpComPort = RtlAllocateHeap( hProcessHeap,
HEAP_ZERO_MEMORY, HEAP_ZERO_MEMORY,
sizeof(COMMPROP) + 0x100 ); sizeof(COMMPROP) + 0x100 );
if(NULL == lpComPort) { if(NULL == lpComPort) {
DPRINT("GetCommConfig() - ERROR_NOT_ENOUGH_MEMORY\n"); DPRINT("GetCommConfig() - ERROR_NOT_ENOUGH_MEMORY\n");
SetLastError(ERROR_NOT_ENOUGH_MEMORY); SetLastError(ERROR_NOT_ENOUGH_MEMORY);