fix possible passing of signed int to function that only receives unsigned ints, CID 3491

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40870 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Alexander von Gluck IV 2011-03-08 15:27:42 +00:00
parent 9f76097f9e
commit 3cd1b88812

View File

@ -34,7 +34,10 @@ void create_log()
return;
int flags = O_WRONLY | O_CREAT | ((gTruncateLogFile) ? O_TRUNC : 0);
close(open(gLogFilePath, flags, 0666));
int filehandle = open(gLogFilePath, flags, 0666);
if (filehandle >= 0)
close(filehandle);
}
mutex_init(&gLogLock, DRIVER_NAME"-logging");
}