Big string bug? Error: Unknown Command
#1

Hy

I'm use an (very) edited Godfather Mode (by me), with use MySQL.

I use bigger strings, for example for Dialog (item list...) - Size is 1024

But now i recently give "Unknown Command" errors on 1-1 (new) commands, but its perfect... (No errors, warning...)
And its a SAMP 0.3 bug? Or its a memory limit problem? (If yes, can i increase this limit?)

Thanx
Reply
#2

Well it is probably just your code. Are you certain you've narrowed it down to just strings?
If you're using an array for players and you exceed that limit with something like 'INVALID_PLAYER_ID' then that would cause a script hault and for the command to return 'unknown command'
Reply
#3

No.
For example i writed a /convert command for convert house files to mysql with a 1024 sized string.
But if i reduced this to 512 its work perfect... So i dont know what is the bug...
Reply
#4

You could show us some code.
Reply
#5

If it is memory limit issue so you can increase stack of memory using
pawn Код:
#pragma dynamic
And if I remember right so 16K is default stack size:
pawn Код:
#pragma dynamic 4096
Reply
#6

Have you increased the MySQL columns buffer size to accomodate the string size? I rarely run into this type of situation so I'm not entirely sure how to prognose it.
Reply
#7

@up: read what he wrote:
Quote:

For example i writed a /convert command for convert house files to mysql with a 1024 sized string.
But if i reduced this to 512 its work perfect...

It has to be a problem with memory limit.
Reply
#8

Quote:
Originally Posted by Balon
If it is memory limit issue so you can increase stack of memory using
pawn Код:
#pragma dynamic
And if I remember right so 16K is default stack size:
pawn Код:
#pragma dynamic 4096
Thanx.
The 4096 is KB, or MB ?

And can you send mi a link for the #pragma commands ?
Reply
#9

KB, https://sampwiki.blast.hk/wiki/Keywordsirectives#.23pragma
Reply
#10

Hmmm, isn't it if get a strval and it contains too many characters, it crashes the runtime on the server.
Then you'll recieve the SERVER: Unknown Command message.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)