aboutsummaryrefslogtreecommitdiff
path: root/i386/include
diff options
context:
space:
mode:
authorFlavio Cruz <flaviocruz@gmail.com>2022-12-06 00:33:41 -0500
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2022-12-06 21:27:53 +0100
commitc925ed9fd3bf4d4fb8a3e6306cda19040cd54627 (patch)
treebb974414bebe35c7dfa24e0396425d1fd5f3d19a /i386/include
parent2a7263559572f178322451a6a1e0a43dc90cdb32 (diff)
downloadgnumach-c925ed9fd3bf4d4fb8a3e6306cda19040cd54627.tar.gz
gnumach-c925ed9fd3bf4d4fb8a3e6306cda19040cd54627.tar.bz2
gnumach-c925ed9fd3bf4d4fb8a3e6306cda19040cd54627.zip
Define vm_size_t and vm_offset_t as __mach_uintptr_t.
This allows *printf to use %zd/%zu/%zx to print vm_size_t and vm_offset_t. Warnings using the incorrect specifiers were fixed. Note that MACH_PORT_NULL became just 0 because GCC thinks that we were comparing a pointer to a character (due to it being an unsigned int) so I removed the explicit cast. Message-Id: <Y47UNdcUF35Ag4Vw@reue>
Diffstat (limited to 'i386/include')
-rw-r--r--i386/include/mach/i386/vm_types.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/i386/include/mach/i386/vm_types.h b/i386/include/mach/i386/vm_types.h
index a50665c8..86e8563a 100644
--- a/i386/include/mach/i386/vm_types.h
+++ b/i386/include/mach/i386/vm_types.h
@@ -72,7 +72,7 @@ typedef unsigned long long_natural_t;
* A vm_offset_t is a type-neutral pointer,
* e.g. an offset into a virtual memory space.
*/
-typedef unsigned long vm_offset_t;
+typedef __mach_uintptr_t vm_offset_t;
typedef vm_offset_t * vm_offset_array_t;
/*
@@ -94,7 +94,7 @@ typedef unsigned long long rpc_phys_addr_t;
* expressing the difference between two
* vm_offset_t entities.
*/
-typedef unsigned long vm_size_t;
+typedef __mach_uintptr_t vm_size_t;
typedef vm_size_t * vm_size_array_t;
/*