Skip to content

Commit

Permalink
Merge pull request #83 from ted-miller/main
Browse files Browse the repository at this point in the history
Explicit casting to resolve warning
  • Loading branch information
ted-miller authored Jul 13, 2023
2 parents 44f4241 + 126c0e4 commit f26d997
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ void Ros_Debug_BroadcastMsg(char* fmt, ...)
//get synchronized time from the agent
int64_t nanosecs = rmw_uros_epoch_nanos();
Ros_Nanos_To_Time_Msg(nanosecs, &debug_msg_timestamp);
strftime(timestamp, FORMATTED_TIME_SIZE, "%a %Y-%m-%d %H:%M:%S", localtime_r(&debug_msg_timestamp.sec, &synced_time));
strftime(timestamp, FORMATTED_TIME_SIZE, "%a %Y-%m-%d %H:%M:%S", localtime_r((const time_t*)&debug_msg_timestamp.sec, &synced_time));
snprintf(timestamp + strlen(timestamp), FORMATTED_TIME_SIZE - strlen(timestamp), ".%03d ", (int)debug_msg_timestamp.nanosec / 1000000);
}
else
Expand Down

0 comments on commit f26d997

Please sign in to comment.