forked from len0rd/rockbox
ignore write data if the length doesn't match what we expect. This avoids the data corruption caused by FS#10319, but doesn't solve the root cause yet (patch by Martin Ritter)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21521 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
e2b018e7fe
commit
057a5802cd
1 changed files with 1 additions and 0 deletions
|
|
@ -472,6 +472,7 @@ void usb_storage_transfer_complete(int ep,int dir,int status,int length)
|
|||
if((unsigned int)length!=(SECTOR_SIZE* cur_cmd.count)
|
||||
&& (unsigned int)length!=WRITE_BUFFER_SIZE) {
|
||||
logf("unexpected length :%d",length);
|
||||
break;
|
||||
}
|
||||
|
||||
unsigned int next_sector = cur_cmd.sector +
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue