Patches item #1749645, was opened at 2007-07-07 15:29 Message generated for change (Comment added) made by subrata_modak You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=303382&aid=1749645&group_id=3382
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Testcases Group: System Calls >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: Helge Deller (hdeller) Assigned to: Nobody/Anonymous (nobody) Summary: lseek09 uses unitialized variable Initial Comment: The testcase lseek09 reads 4 bytes out of a file into a char array, which hasn't been initialized before. The problem is, that the read() syscall only reads the given number of characters (4) but does not add a trailing zero (\0) character. Since the array wasn't zero-initialized before, the 5th character is undefined and (at least on the hppa/parisc architecture) non-zero. The testcase compares then the read-in string (4 chars + some undefined characters) to the fixed string "defg" with strcmp() and strcmp() fails since the 5th caracter is non-zero. Simple one-liner patch attached. Helge ---------------------------------------------------------------------- >Comment By: Subrata (subrata_modak) Date: 2007-07-09 07:19 Message: Logged In: YES user_id=1737361 Originator: NO Thanks. This has been applied and updated. Regards-- Subrata ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=303382&aid=1749645&group_id=3382 ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
