From owner-svn-src-all@freebsd.org Fri Jul 22 19:28:25 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2535CBA1E0A; Fri, 22 Jul 2016 19:28:25 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EC75B1229; Fri, 22 Jul 2016 19:28:24 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u6MJSOM4037031; Fri, 22 Jul 2016 19:28:24 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u6MJSOSP037030; Fri, 22 Jul 2016 19:28:24 GMT (envelope-from np@FreeBSD.org) Message-Id: <201607221928.u6MJSOSP037030@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Fri, 22 Jul 2016 19:28:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r303199 - head/usr.sbin/ctld X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Jul 2016 19:28:25 -0000 Author: np Date: Fri Jul 22 19:28:23 2016 New Revision: 303199 URL: https://svnweb.freebsd.org/changeset/base/303199 Log: ctld(8): Fix MaxBurstLength negotiation. The target must reply with the selected value of MaxBurstSize instead of just echoing back the initiator's offered value. Reviewed by: mav@ Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D7278 Modified: head/usr.sbin/ctld/login.c Modified: head/usr.sbin/ctld/login.c ============================================================================== --- head/usr.sbin/ctld/login.c Fri Jul 22 17:36:40 2016 (r303198) +++ head/usr.sbin/ctld/login.c Fri Jul 22 19:28:23 2016 (r303199) @@ -569,7 +569,7 @@ login_negotiate_key(struct pdu *request, tmp = MAX_BURST_LENGTH; } conn->conn_max_burst_length = tmp; - keys_add(response_keys, name, value); + keys_add_int(response_keys, name, tmp); } else if (strcmp(name, "FirstBurstLength") == 0) { tmp = strtoul(value, NULL, 10); if (tmp <= 0) {