[En-Nut-Discussion] ReadDir fail, wrong retcode in PhatDirEntryRead ?

Jesper Hansen jesperh at telia.com
Wed Jan 25 17:11:20 CET 2006


In PhatDirEntryRead, the return code is 0 if the end of the directory is 
found. This causes (at least) ReadDir to fail or, more correctly, to 
never terminate. The correct return code should have been -1, IMHO.

snippet from PhatDirEntryRead

   } else {
     /* End marker found. */
     srch->phfind_name[0] = 0;
     return -1; <<<<<<<<<<<<<<<<<< shouldn't this have been here ?
   }
   break;



/Jesper



More information about the En-Nut-Discussion mailing list