From 8c9832096315a85f5b481305ee37c18cfd6fbf2a Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Sun, 28 Jan 2018 16:15:32 +0100 Subject: Add const MIG types * hurd/default_pager_types.h (const_recnum_array_t, const_vm_size_array_t): New types. * hurd/hurd_types.h (const_data_t, const_intarray_t, const_fd_mask_t, const_portarray_t, const_pidarray_t, const_idarray_t, const_off_array_t, *const_procinfo_t): New types. --- hurd/default_pager_types.h | 2 ++ hurd/hurd_types.h | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/hurd/default_pager_types.h b/hurd/default_pager_types.h index 99ed3fad..c1f66833 100644 --- a/hurd/default_pager_types.h +++ b/hurd/default_pager_types.h @@ -25,6 +25,8 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ #include /* For recnum_t. */ typedef recnum_t *recnum_array_t; +typedef const recnum_t *const_recnum_array_t; typedef vm_size_t *vm_size_array_t; +typedef const vm_size_t *const_vm_size_array_t; #endif diff --git a/hurd/hurd_types.h b/hurd/hurd_types.h index 9fa9ae29..c072ad21 100644 --- a/hurd/hurd_types.h +++ b/hurd/hurd_types.h @@ -57,13 +57,20 @@ typedef mach_port_t ctty_t; /* These names exist only because of MiG deficiencies. You should not use them in C source; use the normal C types instead. */ typedef char *data_t; +typedef const char *const_data_t; typedef char string_t [1024]; typedef int *intarray_t; +typedef const int *const_intarray_t; typedef int *fd_mask_t; +typedef const int *const_fd_mask_t; typedef mach_port_t *portarray_t; +typedef const mach_port_t *const_portarray_t; typedef pid_t *pidarray_t; +typedef const pid_t *const_pidarray_t; typedef uid_t *idarray_t; +typedef const uid_t *const_idarray_t; typedef loff_t *off_array_t; +typedef const loff_t *const_off_array_t; typedef struct rusage rusage_t; typedef struct flock flock_t; typedef struct utsname utsname_t; @@ -303,6 +310,7 @@ struct procinfo } threadinfos[0]; }; typedef int *procinfo_t; +typedef const int *const_procinfo_t; /* Bits in struct procinfo state: */ #define PI_STOPPED 0x00000001 /* Proc server thinks is stopped. */ -- cgit v1.2.3