From patchwork Wed Jul 20 14:24:09 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pavel Shilovsky X-Patchwork-Id: 991512 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p6KEOLIM018519 for ; Wed, 20 Jul 2011 14:24:21 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751860Ab1GTOYU (ORCPT ); Wed, 20 Jul 2011 10:24:20 -0400 Received: from mail-ew0-f46.google.com ([209.85.215.46]:42908 "EHLO mail-ew0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751854Ab1GTOYU (ORCPT ); Wed, 20 Jul 2011 10:24:20 -0400 Received: by ewy4 with SMTP id 4so562318ewy.19 for ; Wed, 20 Jul 2011 07:24:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:subject:date:message-id:x-mailer; bh=TuQmmUQVhTH31GF+fLZI/X0nbl2ExDn7RT8w9ekS9ek=; b=MGMRbZPBAZps5tDWbccQ5dhpS5m2rcU6AtI3P44eJ4uZRCo+YxOOzFH+kgjFPvxN4l Kzdu3AKImYSB3chVOuduuC3T15KXO5/ukgxsMCVq6e8ZoTYQ9HP7UOZhtMUFXb2UAg+2 +8QTSSHbwqF7d99P5mYKQQlzrwnQjU7KqtbOA= Received: by 10.213.3.136 with SMTP id 8mr291035ebn.143.1311171859123; Wed, 20 Jul 2011 07:24:19 -0700 (PDT) Received: from localhost.localdomain ([178.45.130.118]) by mx.google.com with ESMTPS id a48sm581276eeg.26.2011.07.20.07.24.17 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 20 Jul 2011 07:24:18 -0700 (PDT) From: Pavel Shilovsky To: linux-cifs@vger.kernel.org Subject: [PATCH] CIFS: Fix wrong length in cifs_iovec_read Date: Wed, 20 Jul 2011 18:24:09 +0400 Message-Id: <1311171849-5550-1-git-send-email-piastryyy@gmail.com> X-Mailer: git-send-email 1.7.1 Sender: linux-cifs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-cifs@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Wed, 20 Jul 2011 14:24:21 +0000 (UTC) Signed-off-by: Pavel Shilovsky Reviewed-by: Jeff Layton --- fs/cifs/file.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/fs/cifs/file.c b/fs/cifs/file.c index bb71471..a9b4a24 100644 --- a/fs/cifs/file.c +++ b/fs/cifs/file.c @@ -1737,7 +1737,7 @@ cifs_iovec_read(struct file *file, const struct iovec *iov, io_parms.pid = pid; io_parms.tcon = pTcon; io_parms.offset = *poffset; - io_parms.length = len; + io_parms.length = cur_len; rc = CIFSSMBRead(xid, &io_parms, &bytes_read, &read_data, &buf_type); pSMBr = (struct smb_com_read_rsp *)read_data;