Return-Path: Delivered-To: apmail-incubator-stdcxx-dev-archive@www.apache.org Received: (qmail 38895 invoked from network); 21 Jul 2006 21:35:14 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 21 Jul 2006 21:35:14 -0000 Received: (qmail 87402 invoked by uid 500); 21 Jul 2006 21:35:14 -0000 Delivered-To: apmail-incubator-stdcxx-dev-archive@incubator.apache.org Received: (qmail 87387 invoked by uid 500); 21 Jul 2006 21:35:13 -0000 Mailing-List: contact stdcxx-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: stdcxx-dev@incubator.apache.org Delivered-To: mailing list stdcxx-dev@incubator.apache.org Received: (qmail 87376 invoked by uid 99); 21 Jul 2006 21:35:13 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 14:35:13 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [208.30.140.160] (HELO moroha.quovadx.com) (208.30.140.160) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 14:35:12 -0700 Received: from qxvcexch01.ad.quovadx.com (qxvcexch01.ad.quovadx.com [192.168.170.59]) by moroha.quovadx.com (8.13.6/8.13.4) with ESMTP id k6LLYnkq005222 for ; Fri, 21 Jul 2006 21:34:49 GMT Received: from [10.70.3.113] ([10.70.3.113]) by qxvcexch01.ad.quovadx.com with Microsoft SMTPSVC(6.0.3790.1830); Fri, 21 Jul 2006 15:34:50 -0600 Message-ID: <44C1489A.4060508@roguewave.com> Date: Fri, 21 Jul 2006 15:35:22 -0600 From: Martin Sebor Organization: Rogue Wave Software User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20050920 X-Accept-Language: en-us, en MIME-Version: 1.0 To: stdcxx-dev@incubator.apache.org Subject: Re: runall.sh replacement References: <44B82695.8090307@roguewave.com> <44B83D85.5050503@roguewave.com> <44BD4C03.4080904@roguewave.com> <44BE9798.9080107@roguewave.com> <44BEAB5E.3060500@roguewave.com> <44C00677.2060205@roguewave.com> <44C12F8E.1090708@roguewave.com> In-Reply-To: <44C12F8E.1090708@roguewave.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 21 Jul 2006 21:34:50.0409 (UTC) FILETIME=[7F08A190:01C6AD0D] X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Andrew Black wrote: > Greetings all > > Attached is a slightly modified version of the patch from yesterday. > Changes from the previous version: > - Compatibility layer support (via --compat/--nocompat switches) > - Handle failure to fork() > > I suspect that some changes may be required before submission, but I > also consider this to be in a mostly usable state. [...] Very good! We do need to make a few changes. One is making sure it's (also) valid C++ (since it's now being compiled with C++ compilers). I suspect gcc might let it slide but sigaction() is a C interface that takes a C (i.e., extern "C") function, so handle_alrm() needs to be decorated with extern "C" in C++ (i.e., when __cplusplus is #defined). The other change I'd like to make is to the names of some of the files :) Here's what I'm thinking: watchdog.{cpp,h} --> exec.{cpp,h} parse_opts.{cpp,h} --> cmdopt.{cpp,h} util.{cpp,h} --> ??? I'm not too fond of files named util etc. because they end up being collections of all kinds of odds and ends that don't seem to fit anywhere else, and make a convenient excuse not thinking about the logical organization of a program. We have two functions in util.cpp: terminate() (which should be renamed to something that better expresses the purpose of the function -- i.e., to issue a diagnostic *and* then [maybe] exit), and rw_basename(), the replacement for the UNIX basename(). rw_basename() is only called from runall.c, so it might as well be defined (static) there. terminate() could go in its own file, say diag.{cpp,h}, after being renamed to something like issue_diag(). The whole program should use issue_diag() for all types of diagnostic messages, i.e, for both errors and warnings (with the distinction being that the latter don't cause the program to exit with a non-zero status but allow it to continue). There are other tweaks that I'd like to make to the code but those can be made after the commit. The file name changes should be made prior to it. Could you make the naming changes and resubmit the patch? Also, in your ChangeLog, please avoid using wildcards instead of file names and instead spell out the name of each file in full. Thanks! Martin