Commit fef472b8 authored by Richard P. Curnow's avatar Richard P. Curnow

Fix gaps in date range.

Previously, if the current time was (say) 16:00, and the user did two searches
such as d:jan2006 and d:feb2006, any mails in the interval 31Jan 16:00 through
1Feb 16:00 would appear in neither search output.
parent 0f2c537a
......@@ -333,6 +333,12 @@ int scan_date_string(char *in, time_t *start, int *has_start, time_t *end, int *
time(&now);
start_tm = end_tm = *localtime(&now);
start_tm.tm_hour = 0;
start_tm.tm_min = 0;
start_tm.tm_sec = 0;
end_tm.tm_hour = 23;
end_tm.tm_min = 59;
end_tm.tm_sec = 59;
hyphen = strchr(in, '-');
if (!hyphen) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment