calendar should not core dump How-To-Repeat: fetch http://berklix.com/~jhs/src/bsd/fixes/FreeBSD/src/gen/usr.bin/calendar/core_dump_input.ignore fetch http://berklix.com/~jhs/src/bsd/fixes/FreeBSD/src/gen/usr.bin/calendar/core_dump_shell.ignore ./core_dump_shell.ignore calendar -f core_dump_input.ignore (BTW ignore my strange names ending .ignore, its just a prefix to stop my customise shell installing things in my src/
On 2011-06-09, Julian H. Stacey wrote: > I have verified calendar core dumps on these: > 8.2-RELEASE amd64 > 8.2-RELEASE i386 > & not on these: > 4.11-RELEASE i386 > 6.2-RELEASE i386 > 6.3-RELEASE i386 > 7.3-RELEASE i386 > So there's a regression error to be found & corrected. It looks like this regression is caused by r212035: ------------------------------------------------------------------------ r212035 | edwin | 2010-08-31 01:45:32 +0300 (Tue, 31 Aug 2010) | 3 lines For calendars which don't match the solar-based Gregorian calendar, be able to specify a year string in an entry. ------------------------------------------------------------------------ edwin@ Cc'd. > >Description: > calendar should not core dump > >How-To-Repeat: > > fetch http://berklix.com/~jhs/src/bsd/fixes/FreeBSD/src/gen/usr.bin/calendar/core_dump_input.ignore > fetch http://berklix.com/~jhs/src/bsd/fixes/FreeBSD/src/gen/usr.bin/calendar/core_dump_shell.ignore > ./core_dump_shell.ignore > calendar -f core_dump_input.ignore > > (BTW ignore my strange names ending .ignore, its just a prefix to > stop my customise shell installing things in my src/ -- Jaakko
Responsible Changed From-To: freebsd-bugs->edwin I'll chase it.
Author: edwin Date: Mon Jul 11 22:01:39 2011 New Revision: 223939 URL: http://svn.freebsd.org/changeset/base/223939 Log: Fix run-time breakage when encoutering invalid input-data. PR: bin/157718 Modified: head/usr.bin/calendar/parsedata.c Modified: head/usr.bin/calendar/parsedata.c ============================================================================== --- head/usr.bin/calendar/parsedata.c Mon Jul 11 20:43:59 2011 (r223938) +++ head/usr.bin/calendar/parsedata.c Mon Jul 11 22:01:39 2011 (r223939) @@ -818,6 +818,8 @@ showflags(int flags) static const char * getmonthname(int i) { + if (i <= 0 || i > 12) + return (""); if (nmonths[i - 1].len != 0 && nmonths[i - 1].name != NULL) return (nmonths[i - 1].name); return (months[i - 1]); _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
State Changed From-To: open->patched Fixed in head, MFC later.
For the following conditions Product: Base System, Documentation Status: New, Open, In Progress, UNCONFIRMED Assignee: Former FreeBSD committer Reset to default assignee. Reset status to "Open".
Fixed in all supported branches by base r223939.