Frank Heckenbach a écrit:
Maurice Lombardi wrote:
I had the same results with v2.03p2 (never tried v2.04) y2k.pas has random failures since long time, apparently due to trigger of a Window function to change between summer/winter time when the program changes date to some seconds before y2k to make the test: it appears more clearly, but still randomly, by increasing the time delay included in the test. I simply ignore it.
Well, the test was written to test some "__BP_UNPORTABLE_ROUTINES__" as it clearly indicates. As far as I'm concerned, I don't have to keep this test if it now doesn't even work (reliably) on its "native" platform.
Alternatively, we could activate the work-around (simulate a changed time for the running program and leaving the system time alone) for DJGPP as well. If you prefer this, it's the conditional in dos.pas:741 (`{$ifdef __GO32__}'). Let me know if I should change it permanently.
I had an other look to this bug. It is due to a strange bug when running the test in a W98se DOS window. When running it in bare DOS no error. When making your suggested replacement, no error. The problem is that the delay of 2 seconds which should be produced by sleep(2) is not realized (at the present time ...) when running this test in this DOS window: 2 seconds are felt by bare eye. I can produce it when running under debugger (with rhide), and then the result is correct. I will make some more investigations on sleep in a bare C program, but otherwise you can change the test freely.
Maurice