Xref: utzoo comp.bugs.4bsd:1733 comp.lang.c:35815 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!think.com!hsdndev!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.bugs.4bsd,comp.lang.c Subject: Re: Complexity of reallocating storage (was users command crap) Message-ID: <1521:Feb520:45:5291@kramden.acf.nyu.edu> Date: 5 Feb 91 20:45:52 GMT References: <27AD7A46.343B@tct.uucp> <10210:Feb505:10:2991@kramden.acf.nyu.edu> <1123@gistdev.gist.com> Followup-To: comp.bugs.4bsd Organization: IR Lines: 29 In article <1123@gistdev.gist.com> flint@gistdev.gist.com (Flint Pellett) writes: > 1. If you post any code on usenet, expect it to be criticized. You're right, I overreacted. Sorry. I was hoping for some constructive criticism, though, and it doesn't help to be told something that I had already noted in the code. > 2. It would be nice, if people criticizing code did so as if were a > professional code review. Yes. Among other things, please check the original source, and when it has a comment like /* XXX: We should have some error recovery here! */ then assume that the author does realize that the code can be improved. > 3. Regarding the code: I didn't see the entire example code, but from > the ensuing discussion, I conclude that there was a problem in the > comments in the code. It was stated that the initialization was put > in "for a reason". If the comments were complete, that would have > been obvious, Agreed, and I think that the comment makes it clear enough in context. Geoff, why did you feel compelled to take the code out of context? > 4. A good maintainer (or criticizer) always assumes the original > author did things for reasons. Although in practice most things are done for no reason at all. :-) ---Dan