在 2025-01-04 10:15, LIU Hao 写道:
在 2025-01-04 10:02, Duncan Ogilvie 写道:
Apologies, I am using gmail and was born too late to have learned how
to use a mailing list 😅

Oh welcome; no need to apologize. It's said that GMail doesn't send a correct MIME type for patches, so they may get filtered out. But please don't send a patch inline. Varieties of mail clients can mess up with whitespace characters, making patches inapplicable with `git am`.

Attached is a patch from 
https://sourceforge.net/p/mingw-w64/mingw-w64/merge-requests/27/

Is there a reason why you changed the return type of `RtlMultipleAllocateHeap` from `DWORD` to `ULONG`? They are the same type and interchangeable.

Using `LONG` in place of `NTSTATUS` is fine.


--
Best regards,
LIU Hao
From 3e75e52b9a5d0e0b999230fc91a2f85aba0fcd82 Mon Sep 17 00:00:00 2001
From: Duncan Ogilvie <mr.exodia.tp...@gmail.com>
Date: Sat, 4 Jan 2025 02:34:26 +0100
Subject: [PATCH] Fix a few return types in winnt.h

---
 mingw-w64-headers/include/winnt.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/mingw-w64-headers/include/winnt.h b/mingw-w64-headers/include/winnt.h
index b6d1f58ed..2781198fa 100644
--- a/mingw-w64-headers/include/winnt.h
+++ b/mingw-w64-headers/include/winnt.h
@@ -9705,10 +9705,10 @@ typedef DWORD (WINAPI *PRTL_RUN_ONCE_INIT_FN)(PRTL_RUN_ONCE, PVOID, PVOID *);
 #define VERIFIER_STOP(Code,Msg,P1,S1,P2,S2,P3,S3,P4,S4) { RtlApplicationVerifierStop ((Code),(Msg),(ULONG_PTR)(P1),(S1),(ULONG_PTR)(P2),(S2),(ULONG_PTR)(P3),(S3),(ULONG_PTR)(P4),(S4)); }
 
     VOID NTAPI RtlApplicationVerifierStop(ULONG_PTR Code,PSTR Message,ULONG_PTR Param1,PSTR Description1,ULONG_PTR Param2,PSTR Description2,ULONG_PTR Param3,PSTR Description3,ULONG_PTR Param4,PSTR Description4);
-    NTSYSAPI DWORD NTAPI RtlSetHeapInformation(PVOID HeapHandle,HEAP_INFORMATION_CLASS HeapInformationClass,PVOID HeapInformation,SIZE_T HeapInformationLength);
-    NTSYSAPI DWORD NTAPI RtlQueryHeapInformation(PVOID HeapHandle,HEAP_INFORMATION_CLASS HeapInformationClass,PVOID HeapInformation,SIZE_T HeapInformationLength,PSIZE_T ReturnLength);
-    DWORD NTAPI RtlMultipleAllocateHeap(PVOID HeapHandle,DWORD Flags,SIZE_T Size,DWORD Count,PVOID *Array);
-    DWORD NTAPI RtlMultipleFreeHeap(PVOID HeapHandle,DWORD Flags,DWORD Count,PVOID *Array);
+    NTSYSAPI LONG NTAPI RtlSetHeapInformation(PVOID HeapHandle,HEAP_INFORMATION_CLASS HeapInformationClass,PVOID HeapInformation,SIZE_T HeapInformationLength);
+    NTSYSAPI LONG NTAPI RtlQueryHeapInformation(PVOID HeapHandle,HEAP_INFORMATION_CLASS HeapInformationClass,PVOID HeapInformation,SIZE_T HeapInformationLength,PSIZE_T ReturnLength);
+    ULONG NTAPI RtlMultipleAllocateHeap(PVOID HeapHandle,DWORD Flags,SIZE_T Size,DWORD Count,PVOID *Array);
+    ULONG NTAPI RtlMultipleFreeHeap(PVOID HeapHandle,DWORD Flags,DWORD Count,PVOID *Array);
 
     typedef struct _HARDWARE_COUNTER_DATA {
       HARDWARE_COUNTER_TYPE Type;
-- 
2.43.0

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to