From owner-freebsd-current Mon Jun 24 12:46:38 2002 Delivered-To: freebsd-current@freebsd.org Received: from witchspace.com (pc1-reda4-0-cust134.bre.cable.ntl.com [213.105.81.134]) by hub.freebsd.org (Postfix) with SMTP id 4169D37B401 for ; Mon, 24 Jun 2002 12:46:25 -0700 (PDT) Received: (qmail 95132 invoked from network); 24 Jun 2002 19:46:22 -0000 Received: from lexx.witchspace.com (HELO witchspace.com) (192.168.0.1) by dookie.witchspace.com with SMTP; 24 Jun 2002 19:46:22 -0000 Message-ID: <3D17770E.1060904@witchspace.com> Date: Mon, 24 Jun 2002 20:46:22 +0100 From: Jonathan Belson User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.0.0) Gecko/20020609 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Mark Murray Cc: current@freebsd.org Subject: Re: Perl scripts that need rewiting - Any volunteers? References: <3D0A464B.7040904@witchspace.com> <200206222154.g5MLsva4041792@grimreaper.grondar.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Mark Murray wrote: >>Okay, here's my vidfont/kbdmap rewrite for review. Any feedback >>is welcome, the same goes for bug reports :-) > > Cool, thank you very much! > > Some comments: > > o Please put a copyright on the top of this. By preference, please use > /usr/share/examples/etc/bsd-style-copyright. > > o The code style is generally good, but please don't put braces around > single lines of code, ie use > for (;;) > stuff; > rather than > for (;;) { > stuff; > } > > o Please put all the macro strings like default font and directories into > macros and #include those from (say) vidfont.h. All done. > o Please shorten any long line or comment to less than 80 columns This is quite tricky when using 8 character tabs. Is 4 character indent okay for userland source? > o Please do not use mktemp(); use mkstemp() instead. I used mktemp() to get a filename to redirect to, eg. /* Improvised example */ char *cmd; asprintf(cmd, "prog > %s", mktemp(blah)); system(cmd); free(cmd); I couldn't see a simple way around this, any clues? > o Please make this WARNS=6 clean as far as is possible. Done. Cheers, --Jon http://www.witchsapce.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message