This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
PATCH: Use __syscall_slong_t in bits/mqueue.h
- From: "H.J. Lu" <hongjiu dot lu at intel dot com>
- To: GNU C Library <libc-alpha at sourceware dot org>
- Date: Wed, 16 May 2012 12:30:19 -0700
- Subject: PATCH: Use __syscall_slong_t in bits/mqueue.h
- Reply-to: "H.J. Lu" <hjl dot tools at gmail dot com>
Hi,
This patch uses __syscall_slong_t in bits/mqueue.h to support x32.
Tested on Linux/x86-64. OK to install?
Thanks.
H.J.
* sysdeps/unix/sysv/linux/bits/mqueue.h: Include <sys/types.h>.
(mq_attr): Use __syscall_slong_t.
diff --git a/sysdeps/unix/sysv/linux/bits/mqueue.h b/sysdeps/unix/sysv/linux/bits/mqueue.h
index e755f87..5ce7c8b 100644
--- a/sysdeps/unix/sysv/linux/bits/mqueue.h
+++ b/sysdeps/unix/sysv/linux/bits/mqueue.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2004 Free Software Foundation, Inc.
+/* Copyright (C) 2004-2012 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -19,13 +19,15 @@
# error "Never use <bits/mqueue.h> directly; include <mqueue.h> instead."
#endif
+#include <sys/types.h>
+
typedef int mqd_t;
struct mq_attr
{
- long int mq_flags; /* Message queue flags. */
- long int mq_maxmsg; /* Maximum number of messages. */
- long int mq_msgsize; /* Maximum message size. */
- long int mq_curmsgs; /* Number of messages currently queued. */
- long int __pad[4];
+ __syscall_slong_t mq_flags; /* Message queue flags. */
+ __syscall_slong_t mq_maxmsg; /* Maximum number of messages. */
+ __syscall_slong_t mq_msgsize; /* Maximum message size. */
+ __syscall_slong_t mq_curmsgs; /* Number of messages currently queued. */
+ __syscall_slong_t __pad[4];
};