修正整数比较的编译警告

This commit is contained in:
大石头X2 2017-02-28 20:57:53 +08:00
parent 74206a9bd4
commit 35ce646728
2 changed files with 2 additions and 2 deletions

View File

@ -91,7 +91,7 @@ void ByteArray::move(ByteArray& rval)
void* ByteArray::Alloc(int len)
{
if(len <= sizeof(Arr))
if(len <= (int)sizeof(Arr))
{
_needFree = false;
return Arr;

View File

@ -461,7 +461,7 @@ Task* TaskScheduler::operator[](int taskid)
for(int i=0; i<_Tasks.Count(); i++)
{
auto task = (Task*)_Tasks[i];
if(task->ID == taskid) return task;
if(task->ID == (uint)taskid) return task;
}
return nullptr;