This is the mail archive of the ecos-patches@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

language/c/libc/time/current/tests/strptime fails with assertions enabled


In this test, strptime() does not assign a value to tm1.tm_yday (it is
not told to do so), so it stays uninitialized. As far as I know this is
perfectly legal. The random value of tm_yday causes a CYG_PRECONDITION
in strftime() fail.

I think it would be better to move the precondition tests from the
beginning of strftime() right before the code that does actually use the
tested members of struct tm, so that strftime() will still work if no
uninitialized parts of struct tm are used.


-- 
%SYSTEM-F-ANARCHISM, The operating system has been overthrown

Attachment: strftime.diff
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]