Re: buf, buf1, buf2, arg: J J & E

From: Mike Stilson (mike@c746148-a.ehlls1.pa.home.com)
Date: 07/23/01


On Mon, Jul 23, 2001 at 02:54:17PM -0400, Alex came up with this idea:
>> ACMD(do_foo) {
>>   const char *usage = "Usage: foo [parm] [parm]\r\n";
>>     ch_print(ch, usage);   /* not a printf!! */
> just do "send_to_char(ch, usage);".  There isn't a '%s' in there.

If usage is something like:
const char *usage="prompt %h/%H";
send_to_char(ch, usage);

You get some different output than you'd like.

Not something particularly hard to work around.  Perhaps another
little function to change the %'s to %%'s to be called when
it's possible (read: luser input) to have a % in a string going
to send_to_char.

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/06/01 PST