msvcrt: Aoid TRUE:FALSE conditional expressions.
This commit is contained in:
parent
47e472af10
commit
0409b9895c
|
@ -1771,7 +1771,7 @@ int CDECL MSVCRT__sopen_s( int *fd, const char *path, int oflags, int shflags, i
|
|||
|
||||
sa.nLength = sizeof( SECURITY_ATTRIBUTES );
|
||||
sa.lpSecurityDescriptor = NULL;
|
||||
sa.bInheritHandle = (oflags & MSVCRT__O_NOINHERIT) ? FALSE : TRUE;
|
||||
sa.bInheritHandle = !(oflags & MSVCRT__O_NOINHERIT);
|
||||
|
||||
hand = CreateFileA(path, access, sharing, &sa, creation, attrib, 0);
|
||||
if (hand == INVALID_HANDLE_VALUE) {
|
||||
|
@ -1885,7 +1885,7 @@ int CDECL MSVCRT__wsopen_s( int *fd, const MSVCRT_wchar_t* path, int oflags, int
|
|||
|
||||
sa.nLength = sizeof( SECURITY_ATTRIBUTES );
|
||||
sa.lpSecurityDescriptor = NULL;
|
||||
sa.bInheritHandle = (oflags & MSVCRT__O_NOINHERIT) ? FALSE : TRUE;
|
||||
sa.bInheritHandle = !(oflags & MSVCRT__O_NOINHERIT);
|
||||
|
||||
hand = CreateFileW(path, access, sharing, &sa, creation, attrib, 0);
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@ int CDECL MSVCRT__get_printf_count_output( void )
|
|||
int CDECL MSVCRT__set_printf_count_output( int enable )
|
||||
{
|
||||
BOOL old = n_format_enabled;
|
||||
n_format_enabled = (enable ? TRUE : FALSE);
|
||||
n_format_enabled = enable != 0;
|
||||
return old ? 1 : 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue