Re: [CODE] Better argument processing 97 08:54:47 pm

From: Andrew Helm (ashe@IGLOU.COM)
Date: 09/19/97


[snip]
> ARGS *string_to_args( char *s )
> {
>         char *tok;
>         int ntok = 0;
>         static char *args[MAXTOKEN+1];
>         static ARGS arguments;
[snip

>         return &arguments;
> }

It looks good, but is it safe? Can you return a pointer to a static
variable in the function? (Or rather, not "can" you, but is it going
to mess up any compilers/platforms, that is, is such a thing okay
in ANSI C?).


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST