[code] color code/dropped const pointer

From: Raven Jade Kenago (raventhorne@YAHOO.COM)
Date: 03/21/98


I'm using Jorgen Sigvardsson's color code snippet from
Alex Fletcher's site. When I compiled I got this warning: (warnings
are the enemy)

comm.c: In function `parse_color':
comm.c:705: warning: passing arg 1 of `count_chars' discards `const'
from pointer type

the relevant code:


void write_to_output(const char *txt, struct descriptor_data *t)
{
  int size;
  char *new_txt;

  new_txt = parse_color(txt, t);


char *parse_color(const char *txt, struct descriptor_data *t)

write_to_output gets a const char from send_to_char and send_to_q.
When it calls parse color it drops the const. This doesn't look to me
like it causes any problems, but are there any and either way, how do
I fix/get rid of that warning? If the warning is a non issue I'd still
like to know how to fix it, thanks for any insight..

Raven




_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com


     +------------------------------------------------------------+
     | 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