Update of /cvsroot/arcem/arcem/arch In directory vz-cvs-4.sog:/tmp/cvs-serv11622/arch
Modified Files: Tag: arcem-fast filecommon.c Log Message: HostFS fixes and improvements * arminit.c - Cope properly with the unlikely event of finding a SWI instruction at 0x0 or 0x4 * arch/filecommon.c - Fixed the new file caching code being broken when reading/writing more data than will fit inside the file buffer (1MB) * hostfs.c, support_modules/hostfs/hostfs,ffa, support/hostfs/hostfs.s - Improved error detection and reporting. Failsafe error of HOSTFS_ERROR_UNKNOWN is used if we can't find a specific error to return. Index: filecommon.c =================================================================== RCS file: /cvsroot/arcem/arcem/arch/Attic/filecommon.c,v retrieving revision 1.1.2.2 retrieving revision 1.1.2.3 diff -u -d -r1.1.2.2 -r1.1.2.3 --- filecommon.c 27 Oct 2011 20:57:31 -0000 1.1.2.2 +++ filecommon.c 5 Nov 2011 17:47:14 -0000 1.1.2.3 @@ -90,7 +90,7 @@ { if(filebuffer_buffered == filebuffer_offset) { - if(filebuffer_remain) + if(!filebuffer_remain) return ret; filebuffer_fill(); } @@ -142,9 +142,9 @@ { size_t temp = MIN(uCount,buffer_size-filebuffer_offset); if(endian) - ByteCopy(buffer+filebuffer_offset,pBuffer,uCount); + ByteCopy(buffer+filebuffer_offset,pBuffer,temp); else - memcpy(buffer+filebuffer_offset,pBuffer,uCount); + memcpy(buffer+filebuffer_offset,pBuffer,temp); filebuffer_offset += temp; uCount -= temp; pBuffer += temp; ------------------------------------------------------------------------------ RSA(R) Conference 2012 Save $700 by Nov 18 Register now http://p.sf.net/sfu/rsa-sfdev2dev1 -- arcem-cvs mailing list arcem-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/arcem-cvs