Skip to content

Commit

Permalink
fix:initialize the struct member (#2992)
Browse files Browse the repository at this point in the history
Co-authored-by: chejinge <chejinge@360.cn>
  • Loading branch information
chejinge and brother-jin authored Jan 8, 2025
1 parent 1b0990e commit f0704c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pika_server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1364,8 +1364,8 @@ void PikaServer::AutoDeleteExpiredDump() {
int now_month = now->tm_mon + 1;
int now_day = now->tm_mday;

struct tm dump_time;
struct tm now_time;
struct tm dump_time = {};
struct tm now_time = {};

dump_time.tm_year = dump_year;
dump_time.tm_mon = dump_month;
Expand Down

0 comments on commit f0704c3

Please sign in to comment.