mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:17:44 +00:00
Userland: Stop passing ignored timezones to gettimeofday
This commit is contained in:
parent
ab87d42200
commit
88319b188e
3 changed files with 8 additions and 11 deletions
|
@ -58,7 +58,6 @@ static bool in_ci = false;
|
|||
static struct timeval start_time {
|
||||
0, 0
|
||||
};
|
||||
static struct timezone tz;
|
||||
static bool g_some_test_failed = false;
|
||||
static bool encrypting = true;
|
||||
|
||||
|
@ -476,18 +475,18 @@ auto main(int argc, char** argv) -> int
|
|||
return 1;
|
||||
}
|
||||
|
||||
#define I_TEST(thing) \
|
||||
{ \
|
||||
printf("Testing " #thing "... "); \
|
||||
fflush(stdout); \
|
||||
gettimeofday(&start_time, &tz); \
|
||||
#define I_TEST(thing) \
|
||||
{ \
|
||||
printf("Testing " #thing "... "); \
|
||||
fflush(stdout); \
|
||||
gettimeofday(&start_time, nullptr); \
|
||||
}
|
||||
#define PASS \
|
||||
{ \
|
||||
struct timeval end_time { \
|
||||
0, 0 \
|
||||
}; \
|
||||
gettimeofday(&end_time, &tz); \
|
||||
gettimeofday(&end_time, nullptr); \
|
||||
time_t interval_s = end_time.tv_sec - start_time.tv_sec; \
|
||||
suseconds_t interval_us = end_time.tv_usec; \
|
||||
if (interval_us < start_time.tv_usec) { \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue