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:
@@ -34,7 +34,10 @@ void create_log()
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
int flags = O_WRONLY | O_CREAT | ((gTruncateLogFile) ? O_TRUNC : 0);
|
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");
|
mutex_init(&gLogLock, DRIVER_NAME"-logging");
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user