I was mucking around and came across the following. Given the
following function:
void CTimerDlg::OnStart()
{
time_t start, end;
start = time(NULL);
do {
end = time(NULL);
} while (difftime(end, start) < 60.0);
AfxMessageBox("Time's up");
}
This function would work as expected (that is, the message box would
pop-up 60 seconds after the "start" was pushed) when compiled as a
32-bit app. in MSVC 5.0. However, when compiled as a 16-bit app. in
MSVC 1.5, this loop would time out in 30 - 40 seconds. The tests were
run on a 90 mHz Pentium. Does anybody have an idea?
* KWQ/2 1.2i *
--- TMail v1.31.5
---------------
* Origin: Diablo Valley PCUG-BBS, Walnut Creek, CA 510/943-6238 (1:161/55)
|