On Mon, 16 Aug 1999, Chuck Carson wrote: > When you are adding to a buffer before sending it to the > character, which is the more suitable method? > > 1) > > sprintf (buf + strlen(buf), "blah....."); > > or 2) > > sprintf(buf, "%sblah......", buf); They both work the same, although some compilers (ie Borland) choke on #2, which is why all instances of #2 were replaced with #1 in the Circle codebase (pl13 maybe?) -- "Misery is boundless" -Xual the Torturer, on the Eve of the Sundering. Danathara Online RPG telnet://danathara.dhs.org:4000 +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST