Hygiene of #define DIR \"/usr/lib/news
Larry DeLuca
larry at cci-bdc.UUCP
Fri Feb 15 22:47:32 AEST 1985
In reference to the above style of defines: cute. but it's the same
kind of cute that leads to headaches later. (also to headaches during
when more than one person is working on a project and one goes through
and "fixes" the other one's "mistakes").
it just sets off all sorts of alarm flags in my head. i prefer to
build the string using strncat(3) and then give the built string to
system(2). If you're feeling like doing it better, you can use
sprintf(3) (which i do for more complicated examples than the one above)
to construct the string).
larry...
--
uucp: ..mit-eddie!cybvax0!cci-bdc!larry
arpa: henrik at mit-mc.ARPA
This mind intentionally left blank.
More information about the Comp.lang.c
mailing list