mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-09-24 21:27:17 +02:00
Make builtin formatted strings default to false to avoid trying to perform a format in cases where it can be folled by a following parameters that are not meant to be part of that formatted string.
This commit is contained in:
@@ -25,7 +25,7 @@ static SQInteger SqLoadScript(HSQUIRRELVM vm)
|
||||
// Whether the script execution is delayed
|
||||
SQBool delay = SQFalse;
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 3);
|
||||
StackStrF val(vm, 3, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -1901,7 +1901,7 @@ SQInteger CPlayer::Msg(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, msgidx);
|
||||
StackStrF val(vm, msgidx, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -1982,7 +1982,7 @@ SQInteger CPlayer::MsgP(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 3);
|
||||
StackStrF val(vm, 3, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -2088,7 +2088,7 @@ SQInteger CPlayer::MsgEx(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, msgidx);
|
||||
StackStrF val(vm, msgidx, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -2153,7 +2153,7 @@ SQInteger CPlayer::Message(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -2210,7 +2210,7 @@ SQInteger CPlayer::Announce(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -2280,7 +2280,7 @@ SQInteger CPlayer::AnnounceEx(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 3);
|
||||
StackStrF val(vm, 3, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -36,7 +36,7 @@ template < class T > T BaseHash< T >::Algo;
|
||||
template < class T > static SQInteger HashF(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -56,7 +56,7 @@ template < class T > static SQInteger HashF(HSQUIRRELVM vm)
|
||||
static SQInteger WhirlpoolF(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -94,7 +94,7 @@ static SQInteger WhirlpoolF(HSQUIRRELVM vm)
|
||||
static SQInteger EncodeBase64F(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -122,7 +122,7 @@ static SQInteger EncodeBase64F(HSQUIRRELVM vm)
|
||||
static SQInteger DecodeBase64F(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -153,7 +153,7 @@ static SQInteger SqNan(HSQUIRRELVM vm)
|
||||
return sq_throwerror(vm, "Wrong number of arguments");
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -178,7 +178,7 @@ static SQInteger SqNanL(HSQUIRRELVM vm)
|
||||
return sq_throwerror(vm, "Wrong number of arguments");
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -490,7 +490,7 @@ static SQInteger SplitWhereCharImpl(HSQUIRRELVM vm, int(*fn)(int), bool neg)
|
||||
}
|
||||
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -612,7 +612,7 @@ static SQInteger SqStrExplode(HSQUIRRELVM vm)
|
||||
return sq_throwerror(vm, _SC("Missing string value"));
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 4);
|
||||
StackStrF val(vm, 4, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -812,7 +812,7 @@ static CSStr FromArray(Array & arr)
|
||||
static SQInteger StdPrintF(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -21,7 +21,7 @@ extern void Register_SysPath(HSQUIRRELVM vm);
|
||||
static SQInteger SqSysExec(HSQUIRRELVM vm)
|
||||
{
|
||||
// Attempt to retrieve the value from the stack as a string
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -22,7 +22,7 @@ static SQInteger SqExtractIPv4(HSQUIRRELVM vm)
|
||||
return sq_throwerror(vm, "Missing IP address string");
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -539,7 +539,7 @@ template < Uint8 L, bool S > static SQInteger LogBasicMessage(HSQUIRRELVM vm)
|
||||
return sq_throwerror(vm, "Missing message value");
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -259,7 +259,7 @@ static SQInteger SqBroadcastMsg(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, msgidx);
|
||||
StackStrF val(vm, msgidx, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -339,7 +339,7 @@ static SQInteger SqBroadcastMsgP(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 3);
|
||||
StackStrF val(vm, 3, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -444,7 +444,7 @@ static SQInteger SqBroadcastMsgEx(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, msgidx);
|
||||
StackStrF val(vm, msgidx, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -508,7 +508,7 @@ static SQInteger SqBroadcastMessage(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -564,7 +564,7 @@ static SQInteger SqBroadcastAnnounce(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 2);
|
||||
StackStrF val(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
@@ -641,7 +641,7 @@ static SQInteger SqBroadcastAnnounceEx(HSQUIRRELVM vm)
|
||||
}
|
||||
|
||||
// Attempt to generate the string value
|
||||
StackStrF val(vm, 3);
|
||||
StackStrF val(vm, 3, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(val.mRes))
|
||||
{
|
||||
|
@@ -499,7 +499,7 @@ public:
|
||||
return sq_throwerror(vm, e.what());
|
||||
}
|
||||
// Attempt to generate the string value
|
||||
const StackStrF tag(vm, 2);
|
||||
const StackStrF tag(vm, 2, true);
|
||||
// Have we failed to retrieve the string?
|
||||
if (SQ_FAILED(tag.mRes))
|
||||
{
|
||||
|
Reference in New Issue
Block a user