From 480f92448316d3ec556af09a3f0d15477948cb25 Mon Sep 17 00:00:00 2001 From: mav Date: Thu, 25 Sep 2014 09:12:11 +0000 Subject: [PATCH] MFC r271957: Fix read overrun handling, broken by using wrong variable. Approved by: re (marius) git-svn-id: svn://svn.freebsd.org/base/stable/10@272101 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f --- sys/cam/ctl/ctl_frontend_iscsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/cam/ctl/ctl_frontend_iscsi.c b/sys/cam/ctl/ctl_frontend_iscsi.c index dc1200602..e691bec04 100644 --- a/sys/cam/ctl/ctl_frontend_iscsi.c +++ b/sys/cam/ctl/ctl_frontend_iscsi.c @@ -2509,10 +2509,10 @@ cfiscsi_datamove_in(union ctl_io *io) sg_addr += len; sg_len -= len; - KASSERT(buffer_offset + request->ip_data_len <= expected_len, + KASSERT(buffer_offset + response->ip_data_len <= expected_len, ("buffer_offset %zd + ip_data_len %zd > expected_len %zd", - buffer_offset, request->ip_data_len, expected_len)); - if (buffer_offset + request->ip_data_len == expected_len) { + buffer_offset, response->ip_data_len, expected_len)); + if (buffer_offset + response->ip_data_len == expected_len) { /* * Already have the amount of data the initiator wanted. */ -- 2.45.0