Skip to content

Commit

Permalink
log: Do not pad log string with a space.
Browse files Browse the repository at this point in the history
  • Loading branch information
veox committed Jan 11, 2014
1 parent f6f9502 commit 3ade514
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions logging.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ void _applog(int prio, const char *str, bool force)

if (opt_log_show_date)
{
snprintf(datetime, sizeof(datetime), " [%d-%02d-%02d %02d:%02d:%02d] ",
snprintf(datetime, sizeof(datetime), "[%d-%02d-%02d %02d:%02d:%02d] ",
tm->tm_year + 1900,
tm->tm_mon + 1,
tm->tm_mday,
Expand All @@ -96,7 +96,7 @@ void _applog(int prio, const char *str, bool force)
}
else
{
snprintf(datetime, sizeof(datetime), " [%02d:%02d:%02d] ",
snprintf(datetime, sizeof(datetime), "[%02d:%02d:%02d] ",
tm->tm_hour,
tm->tm_min,
tm->tm_sec);
Expand Down

0 comments on commit 3ade514

Please sign in to comment.