From owner-freebsd-bugs Mon Feb 21 2:30: 6 2000 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 7045C37BD61 for ; Mon, 21 Feb 2000 02:30:01 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id CAA03788; Mon, 21 Feb 2000 02:30:01 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: from knight.cons.org (knight.cons.org [194.233.237.195]) by hub.freebsd.org (Postfix) with ESMTP id CBFBD37BD61 for ; Mon, 21 Feb 2000 02:29:36 -0800 (PST) (envelope-from cracauer@knight.cons.org) Received: (from cracauer@localhost) by knight.cons.org (8.9.3/8.9.3) id LAA01431; Mon, 21 Feb 2000 11:29:31 +0100 (CET) Message-Id: <200002211029.LAA01431@knight.cons.org> Date: Mon, 21 Feb 2000 11:29:31 +0100 (CET) From: cracauer@cons.org Reply-To: cracauer@cons.org To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: bin/16862: strptime "%+" broken in 4.0-current Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 16862 >Category: bin >Synopsis: strptime(..., "%+" ...) dumps core >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Feb 21 02:30:01 PST 2000 >Closed-Date: >Last-Modified: >Originator: Martin Cracauer >Release: FreeBSD-4.0-current from Feb, 17th, 2000 >Organization: BSD User Group Hamburg >Environment: FreeBSD-4.0-current from Feb, 17th, 2000 >Description: Parsing '%+' (time in date(1) format) in strptime dumps core. it works in 3.4-stable. >How-To-Repeat: Run this standalone program: #include #include int main(void) { struct tm tm; if (strptime("Mon Feb 21 11:20:36 MET 2000", "%+", &tm) == NULL) { printf("Parsing failed\n"); exit(1); } printf("Time was '%s'\n", asctime(&tm)); return 0; } Result: #0 0x280c19ee in strcmp () from /usr/lib/libc.so.4 #1 0x2807f0a8 in i386_get_ioperm () from /usr/lib/libc.so.4 #2 0x2807e2e9 in i386_get_ioperm () from /usr/lib/libc.so.4 #3 0x2807f13d in strptime () from /usr/lib/libc.so.4 #4 0x80484b0 in main () at ptime.c:8 #5 0x804842d in _start () >Fix: I'm not sure why this program messes with i386_get_ioperm etc. at all, so I didn't take a shot at it. Someone who messed with strptime in -current should pick it up. Thanks. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message