Compile Error

A forum for reporting bugs NOT related to custom plugins.

Moderator: MacroQuest Developers

cjn
orc pawn
orc pawn
Posts: 19
Joined: Fri Aug 20, 2004 4:21 pm

Compile Error

Post by cjn » Fri Aug 20, 2004 4:34 pm

Hi,

I encountered 2 compile errors when compiling the Latest zip (19/08):

D:\MQ2-Latest\MQ2Main\MQ2Data.cpp(568) : error C2001: newline in constant
D:\MQ2-Latest\MQ2Main\MQ2Data.cpp(569) : error C2143: syntax error : missing ')' before 'if'

Which the corresponding codes(underlined) are:

if (pIniFile=strtok(szIndex,","))
{
if (pSection=strtok(NULL,","))
{
if (!strcmp(pSection,"-1"))
pSection=0;
if (pKey=strtok(NULL,","))
{
if (!strcmp(pKey,"-1"))
pKey=0;
pDefault=strtok(NULL,"?);
if (!pDefault)

pDefault="";
}
}
}

Also, I found out there is a large potion of codes are commented in MQ2Utilities.cpp, from line 2656 to 3065, are they really unnecessary?

My MQ2 works fine most of the time, but sometimes it kicks me to server selection with my character locked for a long time. If I restart EQ, I can't pass thru the login process with error message like "Login server timed out". I have to wait like 10-15 mins before I can login again. I am not sure if it's really the cause.

Thx for replying.

Btw, I am using VC++ R6.0 with SP6.

chickenisgoot
a ghoul
a ghoul
Posts: 84
Joined: Tue Oct 07, 2003 10:52 am

Re: Compile Error

Post by chickenisgoot » Fri Aug 20, 2004 4:36 pm

It's missing a " after the ?

ILikeCheese
decaying skeleton
decaying skeleton
Posts: 2
Joined: Sat Aug 14, 2004 10:10 am

Post by ILikeCheese » Fri Aug 20, 2004 5:23 pm

Something wrong with your source... mine reads:

Code: Select all

			if (!strcmp(pSection,"-1"))
				pSection=0;
			if (pKey=strtok(NULL,","))
			{
				if (!strcmp(pKey,"-1"))
					pKey=0;
				pDefault=strtok(NULL,"¦");
				if (!pDefault)
					pDefault="";
			}