[SCM] libdvbpsi/master: Drop fix-kfreebsd-build.patch, applied upstream.

alessio at users.alioth.debian.org alessio at users.alioth.debian.org
Fri Oct 4 15:35:18 UTC 2013


The following commit has been merged in the master branch:
commit b98518c457d585c1686e47c5eb053a80d4e67da2
Author: Alessio Treglia <alessio at debian.org>
Date:   Fri Oct 4 16:28:37 2013 +0100

    Drop fix-kfreebsd-build.patch, applied upstream.

diff --git a/debian/patches/fix-kfreebsd-build.patch b/debian/patches/fix-kfreebsd-build.patch
deleted file mode 100644
index a2d1e5c..0000000
--- a/debian/patches/fix-kfreebsd-build.patch
+++ /dev/null
@@ -1,126 +0,0 @@
-Description: Fix build failure on kfreebsd
- MSG_CMSG_CLOEXEC is a flag for recvmsg and not recv. Thus rewrite
- {udp,tcp}_open to create sockets with SOCK_CLOEXEC. If SOCK_CLOEXEC is not
- available, FD_CLOEXEC is set instead.
-Author: Sebastian Ramacher <sramacher at debian.org>
-Last-Update: 2013-08-19
-Forwarded: libdvbpsi-devel at videolan.org
----
- examples/dvbinfo/tcp.c |   27 ++++++++++++++++++++++++++-
- examples/dvbinfo/udp.c |   27 ++++++++++++++++++++++++++-
- 2 files changed, 52 insertions(+), 2 deletions(-)
-
---- libdvbpsi.orig/examples/dvbinfo/udp.c
-+++ libdvbpsi/examples/dvbinfo/udp.c
-@@ -47,6 +47,11 @@
- #   include <arpa/inet.h>
- #endif
- 
-+#ifndef SOCK_CLOEXEC
-+#include <unistd.h>
-+#include <fcntl.h>
-+#endif
-+
- #include <assert.h>
- 
- #include "udp.h"
-@@ -211,13 +216,33 @@ int udp_open(const char *interface, cons
- 
-     for (struct addrinfo *ptr = addr; ptr != NULL; ptr = ptr->ai_next )
-     {
-+#ifdef SOCK_CLOEXEC
-+        s_ctl = socket(ptr->ai_family, ptr->ai_socktype | SOCK_CLOEXEC, ptr->ai_protocol);
-+#else
-         s_ctl = socket(ptr->ai_family, ptr->ai_socktype, ptr->ai_protocol);
-+#endif
-         if (s_ctl <= 0)
-         {
-             perror("udp socket error");
-             continue;
-         }
- 
-+#ifndef SOCK_CLOEXEC
-+        int flags = fcntl(s_ctl, F_GETFD);
-+        if (flags == -1)
-+        {
-+            close(s_ctl);
-+            perror("udp socket error");
-+            continue;
-+        }
-+        if (fcntl(s_ctl, F_SETFD, flags | FD_CLOEXEC) == -1)
-+        {
-+            close(s_ctl);
-+            perror("udp socket error");
-+            continue;
-+        }
-+#endif
-+
-         /* Increase the receive buffer size to 1/2MB (8Mb/s during 1/2s)
-          * to avoid packet loss caused in case of scheduling hiccups */
-         setsockopt (s_ctl, SOL_SOCKET, SO_RCVBUF,
-@@ -257,7 +282,7 @@ ssize_t udp_read(int fd, void *buf, size
- {
-     ssize_t err;
- again:
--    err = recv(fd, buf, count, MSG_CMSG_CLOEXEC);
-+    err = recv(fd, buf, count, 0);
-     if (err < 0)
-     {
-         switch(errno)
---- libdvbpsi.orig/examples/dvbinfo/tcp.c
-+++ libdvbpsi/examples/dvbinfo/tcp.c
-@@ -50,6 +50,11 @@
- #   include <arpa/inet.h>
- #endif
- 
-+#ifndef SOCK_CLOEXEC
-+#include <unistd.h>
-+#include <fcntl.h>
-+#endif
-+
- #include "tcp.h"
- 
- #ifdef HAVE_SYS_SOCKET_H
-@@ -98,13 +103,33 @@ int tcp_open(const char *ipaddress, int
- 
-     for (struct addrinfo *ptr = addr; ptr != NULL; ptr = ptr->ai_next )
-     {
-+#ifdef SOCK_CLOEXEC
-+        s_ctl = socket(ptr->ai_family, ptr->ai_socktype | SOCK_CLOEXEC, ptr->ai_protocol);
-+#else
-         s_ctl = socket(ptr->ai_family, ptr->ai_socktype, ptr->ai_protocol);
-+#endif
-         if (s_ctl <= 0)
-         {
-             perror("tcp socket error");
-             continue;
-         }
- 
-+#ifndef SOCK_CLOEXEC
-+        int flags = fcntl(s_ctl, F_GETFD);
-+        if (flags == -1)
-+        {
-+            close(s_ctl);
-+            perror("tcp socket error");
-+            continue;
-+        }
-+        if (fcntl(s_ctl, F_SETFD, flags | FD_CLOEXEC) == -1)
-+        {
-+            close(s_ctl);
-+            perror("tcp socket error");
-+            continue;
-+        }
-+#endif
-+
-         setsockopt (s_ctl, SOL_SOCKET, SO_REUSEADDR, &(int){ 1 }, sizeof (int));
- 
-         result = connect( s_ctl, ptr->ai_addr, ptr->ai_addrlen );
-@@ -126,7 +151,7 @@ ssize_t tcp_read(int fd, void *buf, size
- {
-     ssize_t err;
- again:
--    err = recv(fd, buf, count, MSG_CMSG_CLOEXEC | MSG_WAITALL);
-+    err = recv(fd, buf, count, MSG_WAITALL);
-     if (err < 0)
-     {
-         switch(errno)
diff --git a/debian/patches/series b/debian/patches/series
deleted file mode 100644
index 5ad6215..0000000
--- a/debian/patches/series
+++ /dev/null
@@ -1 +0,0 @@
-fix-kfreebsd-build.patch

-- 
libdvbpsi packaging



More information about the pkg-multimedia-commits mailing list