[vlc-commits] Contribs: update libdsm to 0.3.0

Jean-Baptiste Kempf git at videolan.org
Fri May 18 15:29:18 CEST 2018


vlc/vlc-3.0 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri May 18 15:06:46 2018 +0200| [a579e5026543841d6030c30b3db811b50fcc686a] | committer: Thomas Guillem

Contribs: update libdsm to 0.3.0

(cherry picked from commit 31f77d71aff16e35926c9e54385f36e89f2fddad)
Signed-off-by: Thomas Guillem <thomas at gllm.fr>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=a579e5026543841d6030c30b3db811b50fcc686a
---

 ...netbios-use-time-instead-of-clock_gettime.patch | 68 ----------------------
 contrib/src/libdsm/SHA512SUMS                      |  2 +-
 contrib/src/libdsm/rules.mak                       |  3 +-
 3 files changed, 2 insertions(+), 71 deletions(-)

diff --git a/contrib/src/libdsm/0001-netbios-use-time-instead-of-clock_gettime.patch b/contrib/src/libdsm/0001-netbios-use-time-instead-of-clock_gettime.patch
deleted file mode 100644
index c55edc13cc..0000000000
--- a/contrib/src/libdsm/0001-netbios-use-time-instead-of-clock_gettime.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 9bebdc7ba3da352269ff5b92a2eb568756a3105d Mon Sep 17 00:00:00 2001
-From: Thomas Guillem <thomas at gllm.fr>
-Date: Mon, 12 Feb 2018 10:46:51 +0100
-Subject: [PATCH] netbios: use time() instead of clock_gettime()
-
-We don't need more than second precisions and this function is available on
-more platforms.
----
- src/netbios_ns.c | 11 +++++------
- 1 file changed, 5 insertions(+), 6 deletions(-)
-
-diff --git a/src/netbios_ns.c b/src/netbios_ns.c
-index ff37c55..89992ee 100644
---- a/src/netbios_ns.c
-+++ b/src/netbios_ns.c
-@@ -831,7 +831,6 @@ static void *netbios_ns_discover_thread(void *opaque)
-     netbios_ns *ns = (netbios_ns *) opaque;
-     while (true)
-     {
--        struct timespec tp;
-         const int remove_timeout = 5 * ns->discover_broadcast_timeout;
-         netbios_ns_entry  *entry, *entry_next;
- 
-@@ -840,12 +839,12 @@ static void *netbios_ns_discover_thread(void *opaque)
- 
-         // check if cached entries timeout, the timeout value is 5 times the
-         // broadcast timeout.
--        clock_gettime(CLOCK_REALTIME, &tp);
-+        time_t now = time(NULL);
-         for (entry = TAILQ_FIRST(&ns->entry_queue);
-              entry != NULL; entry = entry_next)
-         {
-             entry_next = TAILQ_NEXT(entry, next);
--            if (tp.tv_sec - entry->last_time_seen > remove_timeout)
-+            if (now - entry->last_time_seen > remove_timeout)
-             {
-                 if (entry->flag & NS_ENTRY_FLAG_VALID_NAME)
-                 {
-@@ -886,7 +885,7 @@ static void *netbios_ns_discover_thread(void *opaque)
-             if (res == 0)
-                 break;
- 
--            clock_gettime(CLOCK_REALTIME, &tp);
-+            time_t now = time(NULL);
- 
-             if (name_query.type == NAME_QUERY_TYPE_NB)
-             {
-@@ -899,7 +898,7 @@ static void *netbios_ns_discover_thread(void *opaque)
-                     if (!entry)
-                         return NULL;
-                 }
--                entry->last_time_seen = tp.tv_sec;
-+                entry->last_time_seen = now;
- 
-                 // if entry is already valid, don't send NBSTAT query
-                 if (entry->flag & NS_ENTRY_FLAG_VALID_NAME)
-@@ -922,7 +921,7 @@ static void *netbios_ns_discover_thread(void *opaque)
-                 if (!entry)
-                     continue;
- 
--                entry->last_time_seen = tp.tv_sec;
-+                entry->last_time_seen = now;
- 
-                 send_callback = !(entry->flag & NS_ENTRY_FLAG_VALID_NAME);
- 
--- 
-2.11.0
-
diff --git a/contrib/src/libdsm/SHA512SUMS b/contrib/src/libdsm/SHA512SUMS
index 48454b57dc..bb3a29cbb8 100644
--- a/contrib/src/libdsm/SHA512SUMS
+++ b/contrib/src/libdsm/SHA512SUMS
@@ -1 +1 @@
-461162010679926baa49027ceecc0fd2565ded37384290494f9511372dd51d053857585dc12d7f93451ee209f60555cc07619e881e6eaff667879ff4285f6254  libdsm-0.2.8.tar.gz
+8a26a4b14ad64b55f830d39641c0879639b2086f9e5cb8d4b6b83314a778844303e4c491aafd98362a9b5ec3eaab9fe7a4cfd5580b055d93553b69b68cdece4a  libdsm-0.3.0.tar.gz
diff --git a/contrib/src/libdsm/rules.mak b/contrib/src/libdsm/rules.mak
index cd37bb6e2e..69b5420cd0 100644
--- a/contrib/src/libdsm/rules.mak
+++ b/contrib/src/libdsm/rules.mak
@@ -1,7 +1,7 @@
 # libdsm
 
 #LIBDSM_GITURL := git://github.com/videolabs/libdsm.git
-LIBDSM_VERSION := 0.2.8
+LIBDSM_VERSION := 0.3.0
 LIBDSM_URL := https://github.com/videolabs/libdsm/releases/download/v$(LIBDSM_VERSION)/libdsm-$(LIBDSM_VERSION).tar.gz
 
 ifeq ($(call need_pkg,"libdsm >= 0.2.0"),)
@@ -20,7 +20,6 @@ endif
 
 libdsm: libdsm-$(LIBDSM_VERSION).tar.gz .sum-libdsm
 	$(UNPACK)
-	$(APPLY) $(SRC)/libdsm/0001-netbios-use-time-instead-of-clock_gettime.patch
 	$(MOVE)
 
 DEPS_libdsm = libtasn1 iconv



More information about the vlc-commits mailing list