diff options
author | Frederic Culot <calcurse@culot.org> | 2009-07-15 19:16:21 +0000 |
---|---|---|
committer | Frederic Culot <calcurse@culot.org> | 2009-07-15 19:16:21 +0000 |
commit | a93d88c370bde6eacef40e65b21efb5eae353b5a (patch) | |
tree | be96c08981bcd75306cd0084471a9415ac98942d /src/args.c | |
parent | 3fe85503732c885bd3833b9c1c56a8a70d45f253 (diff) | |
download | calcurse-a93d88c370bde6eacef40e65b21efb5eae353b5a.zip |
Dates are now written properly again when using the '-r' flag (thanks Chris again for your report).
Diffstat (limited to 'src/args.c')
-rwxr-xr-x | src/args.c | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -1,4 +1,4 @@ -/* $calcurse: args.c,v 1.55 2009/07/12 18:16:11 culot Exp $ */ +/* $calcurse: args.c,v 1.56 2009/07/15 19:16:22 culot Exp $ */ /* * Calcurse - text-based organizer @@ -409,6 +409,8 @@ app_arg (int add_line, date_t *day, long date, int print_note, conf_t *conf, if (recur_item_inday (ra->start, ra->exc, ra->rpt->type, ra->rpt->freq, ra->rpt->until, today)) { + apoint_llist_node_t *apt; + if (regex && regexec (regex, ra->mesg, 0, 0, 0) != 0) continue; @@ -423,8 +425,11 @@ app_arg (int add_line, date_t *day, long date, int print_note, conf_t *conf, arg_print_date (today, conf); print_date = 0; } - apoint_sec2str (apoint_recur_s2apoint_s (ra), RECUR_APPT, today, - apoint_start_time, apoint_end_time); + apt = apoint_recur_s2apoint_s (ra); + apoint_sec2str (apt, RECUR_APPT, today, apoint_start_time, + apoint_end_time); + mem_free (apt->mesg); + mem_free (apt); fputs (" - ", stdout); fputs (apoint_start_time, stdout); fputs (" -> ", stdout); @@ -867,7 +872,7 @@ parse_args (int argc, char **argv, conf_t *conf) } if (tflag) { - io_load_todo (); + io_load_todo (); todo_arg (tnum, Nflag, preg); non_interactive = 1; } @@ -880,6 +885,7 @@ parse_args (int argc, char **argv, conf_t *conf) if (dflag || rflag || sflag) { io_load_app (); + custom_load_conf (conf, 0); /* To get output date format. */ if (dflag) date_arg (ddate, add_line, Nflag, conf, preg); if (rflag || sflag) |