1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-06-16 07:07:13 +02:00

Minor adjustments to the code and several bug-fixes.

This commit is contained in:
Sandu Liviu Catalin
2017-05-05 20:39:25 +03:00
parent 5f4b175005
commit 3ce06d8cbc
4 changed files with 155 additions and 92 deletions

View File

@ -225,7 +225,7 @@ Int64 Chrono::DateRangeToSeconds(Uint16 _year, Uint8 _month, Uint8 _day, Uint16
// Are we within the same year?
if (_year == year_)
{
return std::abs((DayOfYear(_year, _month, _day) - DayOfYear(year_, month_, day_)) * 86400ULL);
return std::abs((DayOfYear(_year, _month, _day) - DayOfYear(year_, month_, day_)) * 86400LL);
}
// Is the start year greater than the end year?
else if (_year > year_)

View File

@ -516,7 +516,7 @@ static SQInteger SplitWhereCharImpl(HSQUIRRELVM vm, int(*fn)(int), bool neg)
if ((fn(*itr) == 0) == neg)
{
// Are there any characters before this match?
if ((itr - last) > 0 && (last != '\0'))
if ((itr - last) > 0 && (*last != '\0'))
{
// Push this chunk of string on the stack
sq_pushstring(vm, last, itr - last);