From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11373 invoked from network); 3 Jan 1997 14:35:16 -0000 Received: from euclid.skiles.gatech.edu (list@130.207.146.50) by coral.primenet.com.au with SMTP; 3 Jan 1997 14:35:16 -0000 Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id JAA19956; Fri, 3 Jan 1997 09:39:27 -0500 (EST) Resent-Date: Fri, 3 Jan 1997 09:39:27 -0500 (EST) Message-Id: <9701031440.AA02058@raven.cg.tuwien.ac.at> Content-Type: text/plain Mime-Version: 1.0 (NeXT Mail 3.3 v118.2) X-Image-Url: http://www.cg.tuwien.ac.at/~rft/XImage/1996-01-15.tiff X-Nextstep-Mailer: Mail 3.3 (Enhance 1.3) Original-Received: by NeXT.Mailer (1.118.2) PP-warning: Illegal Received field on preceding line From: Robert F Tobler Date: Fri, 3 Jan 97 15:40:09 +0100 To: Zsh Workers Subject: Zsh 3.02 Nextstep CLK_TCK question... Reply-To: rft@titus.cg.tuwien.ac.at Resent-Message-ID: <"6A00z2.0.lt4.UeHpo"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/2715 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu I just got zsh 3.0.2 and I have one question concerning CLK_TCK: The workaround for the Nextstep 3.3 bug has been put in at line 719, but why has it been omitted around line 673? This might be dead code for all I know, since I compiled it an ran it and it seemed to work... but it would be hard for me to test different conditions. So if the other place is not dead code, please put the patch in. For that matter, in order to avoid having these patches in two places you could use the following macro definitions: #ifdef _SC_CLK_TCK /* fetch clock ticks per second from sysconf only the first time used */ #define SET_CLK_TCK(_clktck) do { \ if (!(_clktck)) (_clktck) = sysconf(_SC_CLK_TCK); \ } \ while (0) #else # ifdef __NeXT__ /* NeXTStep 3.3 defines CLK_TCK wrongly */ #define SET_CLK_TCK(_clktck) ((_clktck) = 60) # else # ifdef CLK_TCK #define SET_CLK_TCK(_clktck) ((_clktck) = CLK_TCK) # else # ifdef HZ #define SET_CLK_TCK(_clktck) ((_clktck) = HZ) # else #define SET_CLK_TCK(_clktck) ((_clktck) = 60) # endif # endif # endif #endif and use only: SET_CLK_TCK(clktck); at the two points in question. ------------------------------------------------------------------------ Robert F. Tobler - tel:+43(1)58801-4585,fax:5874932 Institute of Computer Graphics - mailto:rft@cg.tuwien.ac.at Vienna University of Technology - http://www.cg.tuwien.ac.at/~rft/