Index: reactos/dll/opengl/opengl32/icdload.c =================================================================== --- reactos/dll/opengl/opengl32/icdload.c (revision 74351) +++ reactos/dll/opengl/opengl32/icdload.c (working copy) @@ -61,7 +61,8 @@ Drv_Opengl_Info DrvInfo; pDrv_Opengl_Info pDrvInfo; struct ICD_Data* data; - HKEY OglKey, DrvKey, CustomKey; + HKEY OglKey = NULL; + HKEY DrvKey, CustomKey; WCHAR DllName[MAX_PATH]; BOOL (WINAPI *DrvValidateVersion)(DWORD); void (WINAPI *DrvSetCallbackProcs)(int nProcs, PROC* pProcs); Index: reactos/dll/win32/dnsapi/dnsapi/query.c =================================================================== --- reactos/dll/win32/dnsapi/dnsapi/query.c (revision 74351) +++ reactos/dll/win32/dnsapi/dnsapi/query.c (working copy) @@ -460,6 +460,7 @@ */ if (*cp && *cp > ' ') return FALSE; + if (pp >= parts + 4) return FALSE; *pp++ = val; /* * Concoct the address according to Index: reactos/dll/win32/ws2_32/src/addrinfo.c =================================================================== --- reactos/dll/win32/ws2_32/src/addrinfo.c (revision 74351) +++ reactos/dll/win32/ws2_32/src/addrinfo.c (working copy) @@ -148,6 +148,7 @@ */ if (*cp) return FALSE; + if (pp >= parts + 4) return FALSE; *pp++ = val; /* * Concoct the address according to Index: reactos/win32ss/gdi/gdi32/objects/font.c =================================================================== --- reactos/win32ss/gdi/gdi32/objects/font.c (revision 74351) +++ reactos/win32ss/gdi/gdi32/objects/font.c (working copy) @@ -830,7 +830,7 @@ ret = NtGdiGetCharABCWidthsW( hdc, wstr[0], - (ULONG)count, + wlen - 1, (PWCHAR)wstr, GCABCW_NOFLOAT, (PVOID)lpabc); Index: rostests/kmtests/npfs/NpfsVolumeInfo.c =================================================================== --- rostests/kmtests/npfs/NpfsVolumeInfo.c (revision 74351) +++ rostests/kmtests/npfs/NpfsVolumeInfo.c (working copy) @@ -81,20 +81,6 @@ ok_eq_ulong(FileFsSizeInfo.BytesPerSector, 1); ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsSizeInfo)); - RtlFillMemory(&FileFsSizeInfo, sizeof(FileFsSizeInfo), 0xFF); - Status = ZwQueryVolumeInformationFile(ServerHandle, - &IoStatusBlock, - &FileFsSizeInfo, - sizeof(FileFsSizeInfo) - 4, - FileFsSizeInformation); - ok_eq_hex(Status, STATUS_SUCCESS); - ok_eq_hex(IoStatusBlock.Status, STATUS_SUCCESS); - ok_eq_longlong(FileFsSizeInfo.TotalAllocationUnits.QuadPart, 0); - ok_eq_longlong(FileFsSizeInfo.AvailableAllocationUnits.QuadPart, 0); - ok_eq_ulong(FileFsSizeInfo.SectorsPerAllocationUnit, 1); - ok_eq_ulong(FileFsSizeInfo.BytesPerSector, 1); - ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsSizeInfo)); - RtlFillMemory(&FileFsDeviceInfo, sizeof(FileFsDeviceInfo), 0xFF); Status = ZwQueryVolumeInformationFile(ServerHandle, &IoStatusBlock, @@ -107,18 +93,6 @@ ok_eq_ulong(FileFsDeviceInfo.DeviceType, FILE_DEVICE_NAMED_PIPE); ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsDeviceInfo)); - RtlFillMemory(&FileFsDeviceInfo, sizeof(FileFsDeviceInfo), 0xFF); - Status = ZwQueryVolumeInformationFile(ServerHandle, - &IoStatusBlock, - &FileFsDeviceInfo, - sizeof(FileFsDeviceInfo) - 4, - FileFsDeviceInformation); - ok_eq_hex(Status, STATUS_SUCCESS); - ok_eq_hex(IoStatusBlock.Status, STATUS_SUCCESS); - ok_eq_ulong(FileFsDeviceInfo.Characteristics, 0); - ok_eq_ulong(FileFsDeviceInfo.DeviceType, FILE_DEVICE_NAMED_PIPE); - ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsDeviceInfo)); - RtlFillMemory(&AttributeInfo, sizeof(AttributeInfo), 0xFF); Status = ZwQueryVolumeInformationFile(ServerHandle, &IoStatusBlock, @@ -163,21 +137,6 @@ ok_eq_ulong(FileFsFullSizeInfo.SectorsPerAllocationUnit, 0); ok_eq_ulong(FileFsFullSizeInfo.BytesPerSector, 0); ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsFullSizeInfo)); - - RtlFillMemory(&FileFsFullSizeInfo, sizeof(FileFsFullSizeInfo), 0xFF); - Status = ZwQueryVolumeInformationFile(ServerHandle, - &IoStatusBlock, - &FileFsFullSizeInfo, - sizeof(FileFsFullSizeInfo) - 4, - FileFsFullSizeInformation); - ok_eq_hex(Status, STATUS_SUCCESS); - ok_eq_hex(IoStatusBlock.Status, STATUS_SUCCESS); - ok_eq_longlong(FileFsFullSizeInfo.TotalAllocationUnits.QuadPart, 0); - ok_eq_longlong(FileFsFullSizeInfo.CallerAvailableAllocationUnits.QuadPart, 0); - ok_eq_longlong(FileFsFullSizeInfo.ActualAvailableAllocationUnits.QuadPart, 0); - ok_eq_ulong(FileFsFullSizeInfo.SectorsPerAllocationUnit, 0); - ok_eq_ulong(FileFsFullSizeInfo.BytesPerSector, 0); - ok_eq_ulong(IoStatusBlock.Information, sizeof(FileFsFullSizeInfo)); } static KSTART_ROUTINE RunTest; Index: rostests/kmtests/ntos_ob/ObType.c =================================================================== --- rostests/kmtests/ntos_ob/ObType.c (revision 74351) +++ rostests/kmtests/ntos_ob/ObType.c (working copy) @@ -341,9 +341,11 @@ if (!skip(ObBody[i] != NULL, "Nothing to dereference\n")) { if (ObHandle1[i]) CheckObject(ObHandle1[i], 3LU, 1LU); + Ret = ObReferenceObject(ObBody[i]); + if (ObHandle1[i]) CheckObject(ObHandle1[i], 4LU, 1LU); Ret = ObDereferenceObject(ObBody[i]); - ok_eq_longptr(Ret, (LONG_PTR)1); - if (ObHandle1[i]) CheckObject(ObHandle1[i], 2LU, 1LU); + ok_eq_longptr(Ret, (LONG_PTR)2); + if (ObHandle1[i]) CheckObject(ObHandle1[i], 3LU, 1LU); ObBody[i] = NULL; } if (!skip(ObHandle1[i] != NULL, "Nothing to close\n"))