Skip to content

Commit

Permalink
Silence some warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
uNetworkingAB committed Jan 16, 2023
1 parent d111d19 commit 53ae0a8
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/LoopData.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ struct alignas(16) LoopData {

void updateDate() {
time_t now = time(0);
struct tm tstruct = {0};
struct tm tstruct = {};
#ifdef _WIN32
/* Micro, fucking soft never follows spec. */
gmtime_s(&tstruct, &now);
Expand All @@ -78,12 +78,12 @@ struct alignas(16) LoopData {
};
snprintf(date, 32, "%.3s, %.2d %.3s %d %.2d:%.2d:%.2d GMT",
wday_name[tstruct.tm_wday],
tstruct.tm_mday,
tstruct.tm_mday % 99,
mon_name[tstruct.tm_mon],
1900 + tstruct.tm_year,
tstruct.tm_hour,
tstruct.tm_min,
tstruct.tm_sec);
(1900 + tstruct.tm_year) % 9999,
tstruct.tm_hour % 99,
tstruct.tm_min % 99,
tstruct.tm_sec % 99);
}

char date[32];
Expand Down

0 comments on commit 53ae0a8

Please sign in to comment.