1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-28 05:46:38 +02:00

Add signal "day_changed", allow date format in logger options path and mask (task #9430)

This commit is contained in:
Sebastien Helleu
2010-01-26 16:36:55 +01:00
parent aa41942ac1
commit 99bfdfd2ff
22 changed files with 463 additions and 171 deletions
+5 -1
View File
@@ -344,7 +344,7 @@ config_day_change_timer_cb (void *data, int remaining_calls)
{
struct timeval tv_time;
struct tm *local_time;
char text_time[1024], *text_time2;
char text_time[256], *text_time2;
struct t_gui_buffer *ptr_buffer;
/* make C compiler happy */
@@ -374,6 +374,10 @@ config_day_change_timer_cb (void *data, int remaining_calls)
if (text_time2)
free (text_time2);
gui_add_hotlist = 1;
/* send signal "day_changed" */
strftime (text_time, sizeof (text_time), "%Y-%m-%d", local_time);
hook_signal_send ("day_changed", WEECHAT_HOOK_SIGNAL_STRING, text_time);
}
config_day_change_old_day = local_time->tm_mday;