rpl_reporting: sprintf -> snprintf
This was failing to compile with AppleClang 14.0.0.14000029. Thanks to Arunesh Choudhary for noticing.
This commit is contained in:
parent
1efdf67e60
commit
15ca6c5a2f
@ -93,13 +93,13 @@ public:
|
||||
localtime_r(&skr, &tm_tmp);
|
||||
start=&tm_tmp;
|
||||
|
||||
sprintf(timestamp, "%02d%02d%02d %02d:%02d:%02d",
|
||||
start->tm_year % 100,
|
||||
start->tm_mon+1,
|
||||
start->tm_mday,
|
||||
start->tm_hour,
|
||||
start->tm_min,
|
||||
start->tm_sec);
|
||||
snprintf(timestamp, sizeof(timestamp), "%02d%02d%02d %02d:%02d:%02d",
|
||||
start->tm_year % 100,
|
||||
start->tm_mon+1,
|
||||
start->tm_mday,
|
||||
start->tm_hour,
|
||||
start->tm_min,
|
||||
start->tm_sec);
|
||||
timestamp[15]= '\0';
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user