Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > d18fa7374095732a0ead4cb4065710a5 > files > 6

iscsi-initiator-utils-6.2.0.871-0.12.el5_4.1.src.rpm

diff -aurp open-iscsi-2.0-871-test4.bnx2i/usr/iscsid.c open-iscsi-2.0-871-test4.bnx2i.work/usr/iscsid.c
--- open-iscsi-2.0-871-test4.bnx2i/usr/iscsid.c	2009-08-11 22:38:42.000000000 -0500
+++ open-iscsi-2.0-871-test4.bnx2i.work/usr/iscsid.c	2009-08-11 22:43:15.000000000 -0500
@@ -217,6 +217,14 @@ static int sync_session(void *data, stru
 		log_warning("Could not read data from db. Using default and "
 			    "currently negotiated values\n");
 		setup_rec_from_negotiated_values(&rec, info);
+		/*
+		 * We might get the local ip address for software. We do not
+		 * want to try and bind a session by ip though.
+		 */
+		if (!strcmp(t->name, "tcp") || !strcmp(t->name, "iser"))
+			memset(rec.iface.ipaddress, 0,
+			       sizeof(rec.iface.ipaddress));
+
 	} else {
 		/*
 		 * we have a valid record and iface so lets merge