Problems with color.c

Posted by Viersehen on Wed 13 Aug 2003 02:42 AM — 7 posts, 25,331 views.

#0
I am implementing Samson's Color v3.0 and i am getting these messages while compiling.

color.c:1174: redefinition of `send_to_char_color'
color.c:1088: `send_to_char_color' previously defined here
color.c:1180: redefinition of `send_to_pager_color'
color.c:1127: `send_to_pager_color' previously defined here

I have looked the code over and nothing looks wrong...
Any suggestions?

Australia Forum Administrator #1
Search for those words - sounds like you have them in the file twice. The definition I mean, not references to them.
#2
Thanks, Samson helped me fix it... This problem has been resolved
#3
I'm running into this trouble as well. There is no errors in the code that I can see. Does anyone know the solution to this??

-Toy
USA #4
For the benefit of others, what turned out to be the problem?
#5
Well, the way it worked for me was this: I downloaded the swrip source code from http://swrip.betterbox.net/source.html, downloaded Samson's code for the color fix. I've used it before on SMAUG so I know it works fine. I followed the instructions, recompiled and got the error message:

gcc -c -g3 -Wall -DNOCRYPT -DREQUESTS color.c
color.c:1189: error: redefinition of `send_to_char_color'
color.c:1103: error: `send_to_char_color' previously defined here
color.c:1195: error: redefinition of `send_to_pager_color'
color.c:1142: error: `send_to_pager_color' previously defined here
make[1]: *** [color.o] Error 1
make[1]: Leaving directory `/home/KK and Li Li/releasev101rip/src'
make: *** [all] Error 2

I didn't change anything in color.c. Not really sure why it's showing a redefinition.

-Toy
#6
Ok, I solved the problem it seems. I found these in mud.h at the bottom of the file:

//#define send_to_char send_to_char_color
//#define send_to_pager send_to_pager_color

I commented them out and everything compiled cleanly and seems to be working ok.

-Toy