mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-02-21 20:27:13 +01:00
Fix a bug in the String library introduced by the previous commit.
This commit is contained in:
parent
3e8250d04b
commit
b023eef797
@ -886,7 +886,7 @@ static SQInteger SplitWhereCharImpl(HSQUIRRELVM vm, int(*fn)(int), bool neg)
|
|||||||
if ((fn(*itr) == 0) == neg)
|
if ((fn(*itr) == 0) == neg)
|
||||||
{
|
{
|
||||||
// Are there any characters before this match?
|
// Are there any characters before this match?
|
||||||
if ((itr - last) > 1 && (last != '\0'))
|
if ((itr - last) > 0 && (last != '\0'))
|
||||||
{
|
{
|
||||||
// Push this chunk of string on the stack
|
// Push this chunk of string on the stack
|
||||||
sq_pushstring(vm, last, itr - last);
|
sq_pushstring(vm, last, itr - last);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user