From: John Hodge Date: Tue, 8 Nov 2011 06:37:29 +0000 (+0800) Subject: Modules/FDDv2 - Added catch for zero-length read X-Git-Tag: rel0.14~131 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=6844966136c3cc3c7e93a2b69977780e84ff65db;p=tpg%2Facess2.git Modules/FDDv2 - Added catch for zero-length read - What is doing such small reads? --- diff --git a/Modules/Storage/FDDv2/main.c b/Modules/Storage/FDDv2/main.c index 1119de86..bbe79f9c 100644 --- a/Modules/Storage/FDDv2/main.c +++ b/Modules/Storage/FDDv2/main.c @@ -174,6 +174,7 @@ Uint64 FDD_ReadFS(tVFS_Node *Node, Uint64 Offset, Uint64 Length, void *Buffer) if( Length > Node->Size ) Length = Node->Size; if( Offset + Length > Node->Size ) Length = Node->Size - Offset; + if( Length == 0 ) return 0; rem_len = Length;