[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

r6585 - glibc-package/branches/glibc-2.22/debian/patches/hurd-i386



Author: sthibault
Date: 2015-09-18 01:19:34 +0000 (Fri, 18 Sep 2015)
New Revision: 6585

Removed:
   glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-af_local_strlen.diff
   glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-select-EINTR.diff
Log:
really remove files

Deleted: glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-af_local_strlen.diff
===================================================================
--- glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-af_local_strlen.diff	2015-09-17 23:53:19 UTC (rev 6584)
+++ glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-af_local_strlen.diff	2015-09-18 01:19:34 UTC (rev 6585)
@@ -1,144 +0,0 @@
-From: Samuel Thibault <samuel.thibault@ens-lyon.org>
-Subject: [PATCH] Fix connect/sendto/sendmsg into making sure to ignore bytes beyond sockaddr length
-
-2014-03-01  Samuel Thibault  <samuel.thibault@ens-lyon.org>
-
-Thanks Tanaka Akira for the report.
-
-* hurd/hurdsocket.h: New file, defines _hurd_sun_path_dupa which duplicates
-ADDR->sun_path with sockaddr LEN limitation.
-* sysdeps/mach/hurd/connect.c: Include <string.h>
-(__connect): Give result of _hurd_sun_path_dupa to name lookup.
-* sysdeps/mach/hurd/sendmsg.c: Likewise.
-* sysdeps/mach/hurd/sendto.c: Likewise.
-* sysdeps/mach/hurd/bind.c: Call _hurd_sun_path_dupa instead of implementing it
-by hand.
-
-Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
-
----
- hurd/hurdsocket.h           |   22 ++++++++++++++++++++++
- sysdeps/mach/hurd/bind.c    |    8 +++-----
- sysdeps/mach/hurd/connect.c |    4 +++-
- sysdeps/mach/hurd/sendmsg.c |    4 +++-
- sysdeps/mach/hurd/sendto.c  |    4 +++-
- 5 files changed, 34 insertions(+), 8 deletions(-)
-
---- /dev/null
-+++ b/hurd/hurdsocket.h
-@@ -0,0 +1,22 @@
-+/* Hurd-specific socket functions
-+   Copyright (C) 2013 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
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, see
-+   <http://www.gnu.org/licenses/>.  */
-+
-+#include <string.h>
-+
-+#define _hurd_sun_path_dupa(__addr, __len) \
-+  strndupa ((__addr)->sun_path, (__len) - offsetof (struct sockaddr_un, sun_path))
---- a/sysdeps/mach/hurd/bind.c
-+++ b/sysdeps/mach/hurd/bind.c
-@@ -25,7 +25,7 @@
- #include <stddef.h>
- #include <hurd/ifsock.h>
- #include <sys/un.h>
--#include <string.h>
-+#include "hurd/hurdsocket.h"
- 
- /* Give the socket FD the local address ADDR (which is LEN bytes long).  */
- int
-@@ -37,13 +37,11 @@ __bind  (int fd, __CONST_SOCKADDR_ARG ad
- 
-   if (addr->sun_family == AF_LOCAL)
-     {
-+      char *name = _hurd_sun_path_dupa (addr, len);
-       /* For the local domain, we must create a node in the filesystem
- 	 using the ifsock translator and then fetch the address from it.  */
-       file_t dir, node, ifsock;
--      char name[len - offsetof (struct sockaddr_un, sun_path) + 1], *n;
--
--      strncpy (name, addr->sun_path, sizeof name - 1);
--      name[sizeof name - 1] = '\0'; /* Make sure */
-+      char *n;
- 
-       dir = __file_name_split (name, &n);
-       if (dir == MACH_PORT_NULL)
---- a/sysdeps/mach/hurd/connect.c
-+++ b/sysdeps/mach/hurd/connect.c
-@@ -22,6 +22,7 @@
- #include <hurd/socket.h>
- #include <sys/un.h>
- #include <hurd/ifsock.h>
-+#include "hurd/hurdsocket.h"
- 
- /* Open a connection on socket FD to peer at ADDR (which LEN bytes long).
-    For connectionless socket types, just set the default address to send to
-@@ -36,9 +37,10 @@ __connect (int fd, __CONST_SOCKADDR_ARG
- 
-   if (addr->sun_family == AF_LOCAL)
-     {
-+      char *name = _hurd_sun_path_dupa (addr, len);
-       /* For the local domain, we must look up the name as a file and talk
- 	 to it with the ifsock protocol.  */
--      file_t file = __file_name_lookup (addr->sun_path, 0, 0);
-+      file_t file = __file_name_lookup (name, 0, 0);
-       if (file == MACH_PORT_NULL)
- 	return -1;
-       err = __ifsock_getsockaddr (file, &aport);
---- a/sysdeps/mach/hurd/sendmsg.c
-+++ b/sysdeps/mach/hurd/sendmsg.c
-@@ -24,6 +24,7 @@
- #include <hurd/fd.h>
- #include <hurd/ifsock.h>
- #include <hurd/socket.h>
-+#include "hurd/hurdsocket.h"
- 
- /* Send a message described MESSAGE on socket FD.
-    Returns the number of bytes sent, or -1 for errors.  */
-@@ -150,9 +151,10 @@ __libc_sendmsg (int fd, const struct msg
-     {
-       if (addr->sun_family == AF_LOCAL)
- 	{
-+	  char *name = _hurd_sun_path_dupa (addr, addr_len);
- 	  /* For the local domain, we must look up the name as a file
- 	     and talk to it with the ifsock protocol.  */
--	  file_t file = __file_name_lookup (addr->sun_path, 0, 0);
-+	  file_t file = __file_name_lookup (name, 0, 0);
- 	  if (file == MACH_PORT_NULL)
- 	    {
- 	      err = errno;
---- a/sysdeps/mach/hurd/sendto.c
-+++ b/sysdeps/mach/hurd/sendto.c
-@@ -22,6 +22,7 @@
- #include <hurd/fd.h>
- #include <hurd/ifsock.h>
- #include <hurd/socket.h>
-+#include "hurd/hurdsocket.h"
- 
- /* Send N bytes of BUF on socket FD to peer at address ADDR (which is
-    ADDR_LEN bytes long).  Returns the number sent, or -1 for errors.  */
-@@ -47,9 +48,10 @@ __sendto (int fd,
- 
-       if (addr->sun_family == AF_LOCAL)
- 	{
-+	  char *name = _hurd_sun_path_dupa (addr, addr_len);
- 	  /* For the local domain, we must look up the name as a file and talk
- 	     to it with the ifsock protocol.  */
--	  file_t file = __file_name_lookup (addr->sun_path, 0, 0);
-+	  file_t file = __file_name_lookup (name, 0, 0);
- 	  if (file == MACH_PORT_NULL)
- 	    return errno;
- 	  err_port = __ifsock_getsockaddr (file, aport);

Deleted: glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-select-EINTR.diff
===================================================================
--- glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-select-EINTR.diff	2015-09-17 23:53:19 UTC (rev 6584)
+++ glibc-package/branches/glibc-2.22/debian/patches/hurd-i386/tg-select-EINTR.diff	2015-09-18 01:19:34 UTC (rev 6585)
@@ -1,28 +0,0 @@
-We need to set MACH_RCV_INTERRUPT to avoid __mach_msg looping on signals, and
-then handle the interruption.
-
----
- hurdselect.c |    7 +++++--
- 1 file changed, 5 insertions(+), 2 deletions(-)
-
---- a/hurd/hurdselect.c
-+++ b/hurd/hurdselect.c
-@@ -332,7 +332,7 @@ _hurd_select (int nfds,
-       mach_msg_option_t options = (timeout == NULL ? 0 : MACH_RCV_TIMEOUT);
-       error_t msgerr;
-       while ((msgerr = __mach_msg (&msg.head,
--				   MACH_RCV_MSG | options,
-+				   MACH_RCV_MSG | MACH_RCV_INTERRUPT | options,
- 				   0, sizeof msg, portset, to,
- 				   MACH_PORT_NULL)) == MACH_MSG_SUCCESS)
- 	{
-@@ -411,6 +411,9 @@ _hurd_select (int nfds,
- 	   effect a poll, so ERR is MACH_RCV_TIMED_OUT when the poll finds no
- 	   message waiting.  */
- 	err = 0;
-+      if (msgerr == MACH_RCV_INTERRUPTED)
-+	/* Interruption on our side (e.g. signal reception).  */
-+	err = EINTR;
- 
-       if (got)
- 	/* At least one descriptor is known to be ready now, so we will


Reply to: