mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-06-05 14:59:55 +00:00
iscsi-initiator-utils: Update to latest
Remove patches for gcc8 issues which are now fixed upstream but differently Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
-22
@@ -1,22 +0,0 @@
|
||||
From 782730a74dd453a3c9bd2b47b79b1797586871fa Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Fri, 1 Jun 2018 18:11:34 -0700
|
||||
Subject: [PATCH] Include limit.h for PATH_MAX
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
libopeniscsiusr/node.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/libopeniscsiusr/node.c b/libopeniscsiusr/node.c
|
||||
index e82bb0d..3438a8f 100644
|
||||
--- a/libopeniscsiusr/node.c
|
||||
+++ b/libopeniscsiusr/node.c
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
+#include <limits.h>
|
||||
|
||||
#include "libopeniscsiusr/libopeniscsiusr.h"
|
||||
#include "misc.h"
|
||||
-41
@@ -1,41 +0,0 @@
|
||||
From 56a56567d4f334b119e60c4ef0ad87edf7b77609 Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Fri, 1 Jun 2018 18:46:19 -0700
|
||||
Subject: [PATCH] libopeniscsiusr/iface: Set strncpy bounds to not overflow
|
||||
|
||||
Fixes warnings found by gcc8
|
||||
|
||||
iface.c:492:47: error: '%s' directive output may be truncated writing up to 4095 bytes into a region of size 4073 [-Werror=format-truncation=]
|
||||
|
||||
iface.c:140:3: note: in expansion of macro '_strncpy'
|
||||
_strncpy((*iface)->transport_name, proc_name + strlen("iscsi_"),
|
||||
^~~~~~~~
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
libopeniscsiusr/iface.c | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/libopeniscsiusr/iface.c b/libopeniscsiusr/iface.c
|
||||
index 955395d..d33363e 100644
|
||||
--- a/libopeniscsiusr/iface.c
|
||||
+++ b/libopeniscsiusr/iface.c
|
||||
@@ -138,7 +138,7 @@ int _iscsi_iface_get_from_sysfs(struct iscsi_context *ctx, uint32_t host_id,
|
||||
|
||||
if (strncmp(proc_name, "iscsi_", strlen("iscsi_")) == 0)
|
||||
_strncpy((*iface)->transport_name, proc_name + strlen("iscsi_"),
|
||||
- sizeof((*iface)->transport_name) / sizeof(char));
|
||||
+ sizeof((*iface)->transport_name) / sizeof(char) - 1);
|
||||
else
|
||||
_strncpy((*iface)->transport_name, proc_name,
|
||||
sizeof((*iface)->transport_name) / sizeof(char));
|
||||
@@ -489,7 +489,8 @@ static int _fill_hw_iface_from_sys(struct iscsi_context *ctx,
|
||||
|
||||
sysfs_iface_dir_path = malloc(PATH_MAX);
|
||||
_alloc_null_check(ctx, sysfs_iface_dir_path, rc, out);
|
||||
- snprintf(sysfs_iface_dir_path, PATH_MAX, "%s/%s",
|
||||
+ sysfs_iface_dir_path[PATH_MAX+strlen(_ISCSI_SYS_IFACE_DIR)] = '\0';
|
||||
+ snprintf(sysfs_iface_dir_path, PATH_MAX+strlen(_ISCSI_SYS_IFACE_DIR)+1, "%s/%s",
|
||||
_ISCSI_SYS_IFACE_DIR, iface_kern_id);
|
||||
|
||||
_good(_sysfs_prop_get_str(ctx, sysfs_iface_dir_path,
|
||||
+1
-3
@@ -11,7 +11,7 @@ DEPENDS = "openssl flex-native bison-native open-isns util-linux"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
|
||||
|
||||
SRCREV ?= "0cfebb10d29382ac1058c950a60a946c28b01e53"
|
||||
SRCREV ?= "bd79e4ed1004a6035d2538a308c5930890421a22"
|
||||
|
||||
SRC_URI = "git://github.com/open-iscsi/open-iscsi \
|
||||
file://initd.debian \
|
||||
@@ -20,8 +20,6 @@ SRC_URI = "git://github.com/open-iscsi/open-iscsi \
|
||||
file://iscsi-initiator.service \
|
||||
file://iscsi-initiator-targets.service \
|
||||
file://set_initiatorname \
|
||||
file://0001-Include-limit.h-for-PATH_MAX.patch \
|
||||
file://0002-libopeniscsiusr-iface-Set-strncpy-bounds-to-not-over.patch \
|
||||
"
|
||||
S = "${WORKDIR}/git"
|
||||
B = "${WORKDIR}/build"
|
||||
|
||||
Reference in New Issue
Block a user