From owner-freebsd-current@FreeBSD.ORG Sun Aug 6 09:37:23 2006 Return-Path: X-Original-To: current@FreeBSD.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 85A3016A4DE; Sun, 6 Aug 2006 09:37:23 +0000 (UTC) (envelope-from marck@rinet.ru) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id D3EE943D45; Sun, 6 Aug 2006 09:37:22 +0000 (GMT) (envelope-from marck@rinet.ru) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.13.6/8.13.6) with ESMTP id k769bLlw037057; Sun, 6 Aug 2006 13:37:21 +0400 (MSD) (envelope-from marck@rinet.ru) Date: Sun, 6 Aug 2006 13:37:21 +0400 (MSD) From: Dmitry Morozovsky To: "Ralf S. Engelschall" In-Reply-To: <20060806082927.GA17297@engelschall.com> Message-ID: <20060806133029.N36363@woozle.rinet.ru> References: <20060805155548.EBE837302F@freebsd-current.sentex.ca> <20060805220746.U9314@woozle.rinet.ru> <20060805223658.X9314@woozle.rinet.ru> <20060806082927.GA17297@engelschall.com> X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0.2 (woozle.rinet.ru [0.0.0.0]); Sun, 06 Aug 2006 13:37:21 +0400 (MSD) Cc: amd64@FreeBSD.org, current@FreeBSD.org Subject: Re: [head tinderbox] failure on amd64/amd64 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Aug 2006 09:37:23 -0000 On Sun, 6 Aug 2006, Ralf S. Engelschall wrote: RSE> > DM> It seems at least on amd64 size_t (strlen() result) is not int. RSE> > RSE> > Or, maybe, the following would be less ugly: RSE> > tdone_str = ctime(&tdone); RSE> > + tdone_str[(strlen(tdone_str) - 1)] = '\0'; Well, next thought: ctime(3) described as POSIX.1 function having fixed length of 26 chars. Is it safe and standards-compliant to save strlen(3) call and just use tdone_str[24] = '\0' ? Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------