You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-27 16:01:57 +03:00
MCOL-3563: fix compiler warnings / type errors.
A previous commit made posix::read changed return value from bool to int. However some callers still expected bool and compared a bool<0 which is always false.
This commit is contained in:
@@ -37,7 +37,7 @@ ListDirectoryTask::~ListDirectoryTask()
|
||||
}
|
||||
|
||||
#define check_error(msg, ret) \
|
||||
if (success<0) \
|
||||
if (!success) \
|
||||
{ \
|
||||
handleError(msg, errno); \
|
||||
return ret; \
|
||||
@@ -85,8 +85,12 @@ bool ListDirectoryTask::run()
|
||||
return true;
|
||||
}
|
||||
|
||||
success = read(buf, getLength());
|
||||
check_error("ListDirectoryTask read", false);
|
||||
err = read(buf, getLength());
|
||||
if (err<0)
|
||||
{
|
||||
handleError("ListDirectoryTask read", errno);
|
||||
return false;
|
||||
}
|
||||
listdir_cmd *cmd = (listdir_cmd *) buf;
|
||||
|
||||
#ifdef SM_TRACE
|
||||
|
Reference in New Issue
Block a user