about summary refs log tree commit diff
path: root/sysdeps/hurd
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2020-06-28 17:00:47 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2020-06-28 18:04:26 +0000
commitd60fdd480d32a9b4bd781cae08e9a8dfb486c3bd (patch)
tree58a8ab12e15e0d8be0fa6ffab45cd8b932b7f152 /sysdeps/hurd
parentfd3df63fb6649720098597ced59eaa3969bbe067 (diff)
downloadglibc-d60fdd480d32a9b4bd781cae08e9a8dfb486c3bd.tar.gz
glibc-d60fdd480d32a9b4bd781cae08e9a8dfb486c3bd.tar.xz
glibc-d60fdd480d32a9b4bd781cae08e9a8dfb486c3bd.zip
hurd: Fix port definition in HURD_PORT_USE_CANCEL
* sysdeps/hurd/include/hurd/port.h: Include <libc-lock.h>.
(HURD_PORT_USE_CANCEL): Add local port variable.
Diffstat (limited to 'sysdeps/hurd')
-rw-r--r--sysdeps/hurd/include/hurd/port.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sysdeps/hurd/include/hurd/port.h b/sysdeps/hurd/include/hurd/port.h
index 7828dd6fc1..e8c4b71338 100644
--- a/sysdeps/hurd/include/hurd/port.h
+++ b/sysdeps/hurd/include/hurd/port.h
@@ -2,6 +2,8 @@
 #include_next <hurd/port.h>
 
 #ifndef _ISOMAC
+#include <libc-lock.h>
+
 struct _hurd_port_use_data
   {
      struct hurd_port *p;
@@ -14,6 +16,7 @@ extern void _hurd_port_use_cleanup (void *arg);
 /* Like HURD_PORT_USE, but cleans fd on cancel.  */
 #define	HURD_PORT_USE_CANCEL(portcell, expr)				      \
   ({ struct _hurd_port_use_data __d;					      \
+     mach_port_t port;							      \
      __typeof(expr) __result;						      \
      void *__crit;							      \
      __d.p = (portcell);						      \