Core/Commands: Add stupid-check for trying to add negative itemID to vendor. Fixes crash #3238
This commit is contained in:
@@ -168,7 +168,11 @@ public:
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32 itemId = atol(pitem);
|
int32 item_int = atol(pitem);
|
||||||
|
if (item_int <= 0)
|
||||||
|
return true;
|
||||||
|
|
||||||
|
uint32 itemId = item_int;
|
||||||
|
|
||||||
char* fmaxcount = strtok(NULL, " "); //add maxcount, default: 0
|
char* fmaxcount = strtok(NULL, " "); //add maxcount, default: 0
|
||||||
uint32 maxcount = 0;
|
uint32 maxcount = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user