Originally posted by [b]M1dN1ght[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=4130
When I compile the repository I have these errors:
QUOTE
..\src\char_sql\int_guild.c(1599) : warning C4244: 'initializing' : conversion from 'uint64' to 'unsigned int', possible loss of data
..\src\char_sql\int_guild.c(1604) : warning C4244: '=' : conversion from 'uint64' to 'unsigned int', possible loss of data
..\src\char_sql\int_guild.c(1599) : warning C4244: 'initializing' : conversion from 'uint64' to 'unsigned int', possible loss of data
..\src\char_sql\int_guild.c(1604) : warning C4244: '=' : conversion from 'uint64' to 'unsigned int', possible loss of data
Possible correction:
Change:
CODE
unsigned int exp, old_exp=g->member[i].exp;
To:
CODE
unsigned int exp, old_exp= (unsigned int) g->member[i].exp;
And:
CODE
exp = g->member[i].exp - old_exp;
To:
CODE
exp = (unsigned int) g->member[i].exp - old_exp;
Only add cast's to 'unsigned int' to "force" the convertion to unsigned integer.
This post has been edited by M1dN1ght: Mar 16 2010, 08:09 PM