From af752b041e5985596aed2ec27b725735a451e841 Mon Sep 17 00:00:00 2001 From: Alan Stern Date: Fri, 24 Aug 2007 16:27:50 -0400 Subject: [PATCH] --- yaml --- r: 67870 b: refs/heads/master c: 12943f097e5a4a0550f52f98ab8f476435e2ce15 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/usb/gadget/file_storage.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 3a52da262f4a..e9e39e3a3634 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 94d0f7eac77a84da2cee41b8038796891f75f09e +refs/heads/master: 12943f097e5a4a0550f52f98ab8f476435e2ce15 diff --git a/trunk/drivers/usb/gadget/file_storage.c b/trunk/drivers/usb/gadget/file_storage.c index 9998cd7af418..0551140010ee 100644 --- a/trunk/drivers/usb/gadget/file_storage.c +++ b/trunk/drivers/usb/gadget/file_storage.c @@ -2964,7 +2964,7 @@ static int received_cbw(struct fsg_dev *fsg, struct fsg_buffhd *bh) /* Is the CBW meaningful? */ if (cbw->Lun >= MAX_LUNS || cbw->Flags & ~USB_BULK_IN_FLAG || - cbw->Length < 6 || cbw->Length > MAX_COMMAND_SIZE) { + cbw->Length <= 0 || cbw->Length > MAX_COMMAND_SIZE) { DBG(fsg, "non-meaningful CBW: lun = %u, flags = 0x%x, " "cmdlen %u\n", cbw->Lun, cbw->Flags, cbw->Length);