1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-05 03:16:45 +02:00

create empty config file if none found && make default time 24 hours

This commit is contained in:
Jfreegman
2014-04-07 18:16:38 -04:00
parent 5976d33fef
commit de3a28c6e6
5 changed files with 11 additions and 8 deletions

View File

@ -92,7 +92,7 @@ static void update_friend_last_online(int32_t num, uint64_t timestamp)
friends[num].last_online.tm = *localtime(&timestamp);
/* if the format changes make sure TIME_STR_SIZE is the correct size */
const char *t = user_settings->time == TIME_24 ? "%H:%M" : "%I:%M %p";
const char *t = user_settings->time == TIME_12 ? "%I:%M %p" : "%H:%M";
strftime(friends[num].last_online.hour_min_str, TIME_STR_SIZE, t,
&friends[num].last_online.tm);
}