summaryrefslogtreecommitdiff
path: root/security/gvm-libs/files/patch-base_hosts.c
diff options
context:
space:
mode:
authorJose Alonso Cardenas Marquez <acm@FreeBSD.org>2021-11-05 11:31:27 -0500
committerJose Alonso Cardenas Marquez <acm@FreeBSD.org>2021-11-05 11:32:20 -0500
commit77f5aa5d324bbd3771bda67e493cfa6ca55337f7 (patch)
tree29341ab30cb695644be2297722666ad333bbb2d1 /security/gvm-libs/files/patch-base_hosts.c
parentdatabases/redis-devel: update to the recent commit (diff)
security/gvm: update to 21.4.3
The following ports part of security gvm were updated security/gvmd: Update to 21.4.4 security/gvm-libs: Update to 21.4.3 security/openvas: Update to 21.4.3 security/py-ospd-openvas: Update to 21.4.3 security/py-ospd: Update to 21.4.4 security/greenbone-security-assistant: Update to 21.4.3 security/py-gvm-tools: Update to 21.10.0 security/py-python-gvm: Update to 21.10.0
Diffstat (limited to 'security/gvm-libs/files/patch-base_hosts.c')
-rw-r--r--security/gvm-libs/files/patch-base_hosts.c26
1 files changed, 19 insertions, 7 deletions
diff --git a/security/gvm-libs/files/patch-base_hosts.c b/security/gvm-libs/files/patch-base_hosts.c
index 48f41f7af67f..20cdbd489f1a 100644
--- a/security/gvm-libs/files/patch-base_hosts.c
+++ b/security/gvm-libs/files/patch-base_hosts.c
@@ -1,5 +1,5 @@
---- base/hosts.c 2020-12-30 14:04:30.773110000 -0500
-+++ base/hosts.c 2020-12-30 23:46:15.994709000 -0500
+--- base/hosts.c 2021-10-11 09:38:23.000000000 -0500
++++ base/hosts.c 2021-10-27 21:07:36.955872000 -0500
@@ -34,11 +34,11 @@
#include <arpa/inet.h> /* for inet_pton, inet_ntop */
#include <assert.h> /* for assert */
@@ -13,16 +13,16 @@
#include <string.h> /* for strchr, memcpy, memcmp, bzero, strcasecmp */
#include <sys/socket.h> /* for AF_INET, AF_INET6, sockaddr */
-@@ -1068,7 +1068,7 @@
+@@ -1092,7 +1092,7 @@
hosts->count -= duplicates;
- hosts->removed += duplicates;
+ hosts->duplicated += duplicates;
hosts->current = 0;
- malloc_trim (0);
+ // malloc_trim (0);
}
/**
-@@ -1263,7 +1263,7 @@
+@@ -1287,7 +1287,7 @@
gvm_hosts_deduplicate (hosts);
g_strfreev (split);
@@ -31,7 +31,7 @@
return hosts;
}
-@@ -1410,8 +1410,8 @@
+@@ -1467,8 +1467,8 @@
gvm_vhost_t *vhost;
new = gvm_host_new ();
@@ -42,7 +42,7 @@
{
new->type = HOST_TYPE_IPV6;
memcpy (&new->addr6, ip6, sizeof (new->addr6));
-@@ -1419,7 +1419,7 @@
+@@ -1476,7 +1476,7 @@
else
{
new->type = HOST_TYPE_IPV4;
@@ -51,3 +51,15 @@
}
vhost =
gvm_vhost_new (g_strdup (host->name), g_strdup ("Forward-DNS"));
+@@ -2034,7 +2034,11 @@
+ ret->addr.s_addr = host->addr.s_addr;
+ break;
+ case HOST_TYPE_IPV6:
++#if defined (__FreeBSD__)
++ ret->addr6.__u6_addr = host->addr6.__u6_addr;
++#else
+ ret->addr6.__in6_u = host->addr6.__in6_u;
++#endif
+ break;
+ default:
+ g_free (ret);