From 9cedd5b07c11573de4b35605161b5f37c075b671 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Sun, 4 Nov 2018 04:17:09 +0000 Subject: [PATCH] Merge r7435 from trunk git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.3.x@7688 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- iscsi-scst/kernel/iscsi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/iscsi-scst/kernel/iscsi.c b/iscsi-scst/kernel/iscsi.c index b30782060..c817eaf2d 100644 --- a/iscsi-scst/kernel/iscsi.c +++ b/iscsi-scst/kernel/iscsi.c @@ -3950,7 +3950,6 @@ static int iscsi_get_initiator_port_transport_id(struct scst_tgt *tgt, union iscsi_sid sid; int tr_id_size; uint8_t *tr_id; - uint8_t q; TRACE_ENTRY(); @@ -3965,7 +3964,7 @@ static int iscsi_get_initiator_port_transport_id(struct scst_tgt *tgt, sid.id.tsih = 0; tr_id_size = 4 + strlen(sess->initiator_name) + 5 + - snprintf(&q, sizeof(q), "%llx", sid.id64) + 1; + snprintf(NULL, 0, "%llx", sid.id64) + 1; tr_id_size = (tr_id_size + 3) & -4; tr_id = kzalloc(tr_id_size, GFP_KERNEL);