diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2006-12-01 15:14:46 +0000 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2006-12-01 15:14:46 +0000 |
commit | 8ffbfe4b2cdf05dd81bc354fd61db8a323a5a5dd (patch) | |
tree | 05bdf2ce555cbf52406e4a9bc6ee6cfdf1c66ae6 /src | |
parent | 7ce144e8750ad20d5aff59b6bdb08943024774c2 (diff) | |
download | weechat-8ffbfe4b2cdf05dd81bc354fd61db8a323a5a5dd.zip |
Fixed charset bug when displaying "Day changed" message
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/curses/gui-curses-main.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/curses/gui-curses-main.c b/src/gui/curses/gui-curses-main.c index 0ef89bcad..a7e5be549 100644 --- a/src/gui/curses/gui-curses-main.c +++ b/src/gui/curses/gui-curses-main.c @@ -70,7 +70,7 @@ gui_main_loop () t_irc_server *ptr_server; t_gui_buffer *ptr_buffer; int old_day, old_min, old_sec, diff; - char text_time[1024]; + char text_time[1024], *text_time2; time_t new_time; struct tm *local_time; @@ -110,6 +110,7 @@ gui_main_loop () { strftime (text_time, sizeof (text_time), cfg_look_day_change_timestamp, local_time); + text_time2 = weechat_iconv_to_internal (NULL, text_time); gui_add_hotlist = 0; for (ptr_buffer = gui_buffers; ptr_buffer; ptr_buffer = ptr_buffer->next_buffer) @@ -117,8 +118,11 @@ gui_main_loop () if (ptr_buffer->type == BUFFER_TYPE_STANDARD) gui_printf_nolog_notime (ptr_buffer, _("Day changed to %s\n"), - text_time); + (text_time2) ? + text_time2 : text_time); } + if (text_time2) + free (text_time2); gui_add_hotlist = 1; } old_day = local_time->tm_mday; |