Re: [NEWBIE?] Structures (repost)

From: George (gagreer@dragon.ham.muohio.edu)
Date: 09/20/96


On Thu, 19 Sep 1996, Brian Christopher Guilbault wrote:
> this went outon Monday.

Really? Hrm...must've been delete happy that day...

> char *email[EMAIL_LENGTH+1]

char email[EMAIL_LENGTH+1]

> 	CREATE(d->character->email, char, strlen(arg) + 1;
> 	strncpy(d->character->email, arg, EMAIL_LENGTH);

Don't need to do this with email[EMAIL_LENGTH+1]

If you _really_ want to use create, try 'char *email;', then use
your CREATE and strncpy.  Advantage is that people with no email
won't use the memory for it but you have to use an array of
characters email[EMAIL_LENGTH+1] for the pfile, so each record is
the same length....

-George
+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   http://cspo.queensu.ca/~fletcher/Circle/list_faq.html   |
+-----------------------------------------------------------+



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