Re: [CODE] Verify function

From: George (greerga@CIRCLEMUD.ORG)
Date: 06/26/98


On Fri, 26 Jun 1998, James Turner wrote:

>(Note: I wrote the above about an hour ago.  I changed it to use a
>static pointer now.  Makes the functions more self-contained and
>easier to use IMO, since if you wanted to call them from elsewhere
>there wouldn't be any need to worry about freeing the string and
>such).

void verify_function(int (vnum/rnum), char * write, int len)
{
  int c = 0;
  *write = '\0';

  if (...)
    c += snprintf(write + c, len - c, "...", ...);
  if (,,,)
    c += snprintf(write + c, len - c, ",,,", ,,,);

  ...etc...
}

--
George Greer, greerga@circlemud.org | Genius may have its limitations, but
http://patches.van.ml.org/          | stupidity is not thus handicapped.
http://www.van.ml.org/CircleMUD/    |                  -- Elbert Hubbard


     +------------------------------------------------------------+
     | 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/15/00 PST