diff options
author | trasz <trasz@FreeBSD.org> | 2014-06-18 17:21:38 +0000 |
---|---|---|
committer | trasz <trasz@FreeBSD.org> | 2014-06-18 17:21:38 +0000 |
commit | 9975d0a2a6425a1d7affd9ed8615f3f9d43d1b4f (patch) | |
tree | 6363f3254cbba46b314d3f9dd4ec1e56f2c78f26 /usr.sbin | |
parent | f48544ce4a79fbf83492ed6b432952e26883b912 (diff) | |
download | FreeBSD-src-9975d0a2a6425a1d7affd9ed8615f3f9d43d1b4f.zip FreeBSD-src-9975d0a2a6425a1d7affd9ed8615f3f9d43d1b4f.tar.gz |
Get rid of unneccessary argument.
Sponsored by: The FreeBSD Foundation
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/iscsid/login.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/usr.sbin/iscsid/login.c b/usr.sbin/iscsid/login.c index ad8b22a..0d6464b 100644 --- a/usr.sbin/iscsid/login.c +++ b/usr.sbin/iscsid/login.c @@ -159,11 +159,12 @@ login_target_error_str(int class, int detail) } static struct pdu * -login_receive(struct connection *conn, bool initial) +login_receive(struct connection *conn) { struct pdu *response; struct iscsi_bhs_login_response *bhslr; const char *errorstr; + static bool initial = true; response = pdu_new(conn); pdu_receive(response); @@ -201,6 +202,8 @@ login_receive(struct connection *conn, bool initial) } conn->conn_statsn = ntohl(bhslr->bhslr_statsn); + initial = false; + return (response); } @@ -550,7 +553,7 @@ login_negotiate(struct connection *conn) pdu_delete(request); request = NULL; - response = login_receive(conn, false); + response = login_receive(conn); response_keys = keys_new(); keys_load(response_keys, response); for (i = 0; i < KEYS_MAX; i++) { @@ -742,7 +745,7 @@ login_chap(struct connection *conn) login_send_chap_a(conn); log_debugx("waiting for CHAP_A/CHAP_C/CHAP_I"); - response = login_receive(conn, false); + response = login_receive(conn); log_debugx("sending CHAP_N/CHAP_R"); login_send_chap_r(response); @@ -753,7 +756,7 @@ login_chap(struct connection *conn) */ log_debugx("waiting for CHAP result"); - response = login_receive(conn, false); + response = login_receive(conn); if (conn->conn_conf.isc_mutual_user[0] != '\0') login_verify_mutual(response); pdu_delete(response); @@ -831,7 +834,7 @@ login(struct connection *conn) pdu_send(request); pdu_delete(request); - response = login_receive(conn, true); + response = login_receive(conn); response_keys = keys_new(); keys_load(response_keys, response); |