diff options
author | Lukas Fleischer <calcurse@cryptocrack.de> | 2012-06-25 22:13:42 +0200 |
---|---|---|
committer | Lukas Fleischer <calcurse@cryptocrack.de> | 2012-06-30 14:34:34 +0200 |
commit | b97c2a09cffa9963fd0f5086e5da6031b1d48342 (patch) | |
tree | cc034e41ecca4268fb509f0039ecd46259bf5c59 /src/args.c | |
parent | f3858d899c9b29e38521e4eab46dcd97dc3fb57f (diff) | |
download | calcurse-b97c2a09cffa9963fd0f5086e5da6031b1d48342.zip |
day_store_items(): Return the number of items found
Return the total number of items found instead of the pad length, since
this is used to store items in non-interactive mode as well now. The pad
length can still be calculated by using the appointment and event count
parameters.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Diffstat (limited to 'src/args.c')
-rw-r--r-- | src/args.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -295,14 +295,14 @@ app_arg(int add_line, struct date *day, long date, const char *fmt_apt, int n = day_store_items(date, NULL, NULL, regex); - if (n > 1) { + if (n > 0) { if (add_line) fputs("\n", stdout); arg_print_date(date); day_write_stdout(date, fmt_apt, fmt_rapt, fmt_ev, fmt_rev); } - return n - 1; + return n; } /* |