MySQL - sscanf overflow.
#1

Hi.
I've got this MySQL script, and I'm having some problems with it.
As soon as I enter /login password, it prints "sscanf string overflow." into the server console. It does however authenticate it, but doesn't load any stats.

I understood that it's because it's somehow receiving more information than it is actually set to receive. I don't know why though, this is basically it:

pawn Код:
new
        values[5];

    sscanf(Query, "p<|>{s[24]s[129]s[16]}a<i>[5]", values); // s[24] = Playername. [s129] whirlpool pass s[16] IP, and <i> [5] = listed under this.

    gPlayerInfo[playerid][pAdmin]  = values[0];

    GivePlayerMoney(playerid, values[1]);
    SetPlayerScore(playerid, values[2]);
   
    gPlayerInfo[playerid][pLevel] = values[3];
    gPlayerInfo[playerid][pPoints] = values[4];

    gPlayerInfo[playerid][pLoggedIn] = true;
   
    SendClientMessage(playerid, COLOR_GREEN, "** [INFO] You have succesfully authenticated. Your stats have been loaded.");
    PlayerPlaySound(playerid, 1056, playerid, playerid, playerid);
I have a global array on top of the script (Query), which is 1024cells long.
Why is my script doing this?
Reply


Messages In This Thread
MySQL - sscanf overflow. - by shitbird - 07.06.2011, 23:04
Re: MySQL - sscanf overflow. - by Scenario - 07.06.2011, 23:22
Re: MySQL - sscanf overflow. - by shitbird - 07.06.2011, 23:27

Forum Jump:


Users browsing this thread: 2 Guest(s)