From 189ac56e6d673a505208ac6de9e741affc55d1c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Delanoy?= Date: Tue, 22 Oct 2013 22:21:51 +0200 Subject: [PATCH] wineboot: Use BOOL type where appropriate. --- programs/wineboot/shutdown.c | 4 ++-- programs/wineboot/wineboot.c | 19 ++++++++++--------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/programs/wineboot/shutdown.c b/programs/wineboot/shutdown.c index ac3019cfe32..a5f5f5af1f9 100644 --- a/programs/wineboot/shutdown.c +++ b/programs/wineboot/shutdown.c @@ -335,14 +335,14 @@ static BOOL CALLBACK shutdown_one_desktop( LPWSTR name, LPARAM force ) if (hdesk == NULL) { WINE_ERR("Cannot open desktop %s, err=%i\n", wine_dbgstr_w(name), GetLastError()); - return 0; + return FALSE; } if (!SetThreadDesktop( hdesk )) { CloseDesktop( hdesk ); WINE_ERR("Cannot set thread desktop %s, err=%i\n", wine_dbgstr_w(name), GetLastError()); - return 0; + return FALSE; } CloseDesktop( hdesk ); diff --git a/programs/wineboot/wineboot.c b/programs/wineboot/wineboot.c index 4f9adb0f68f..a062d811a65 100644 --- a/programs/wineboot/wineboot.c +++ b/programs/wineboot/wineboot.c @@ -948,7 +948,7 @@ static HANDLE start_rundll32( const char *inf_path, BOOL wow64 ) } /* execute rundll32 on the wine.inf file if necessary */ -static void update_wineprefix( int force ) +static void update_wineprefix( BOOL force ) { const char *config_dir = wine_get_config_dir(); char *inf_path = get_wine_inf_path(); @@ -1123,11 +1123,12 @@ int main( int argc, char *argv[] ) /* First, set the current directory to SystemRoot */ int optc; - int end_session = 0, force = 0, init = 0, kill = 0, restart = 0, shutdown = 0, update = 0; + BOOL end_session, force, init, kill, restart, shutdown, update; HANDLE event; SECURITY_ATTRIBUTES sa; BOOL is_wow64; + end_session = force = init = kill = restart = shutdown = update = FALSE; GetWindowsDirectoryW( windowsdir, MAX_PATH ); if( !SetCurrentDirectoryW( windowsdir ) ) WINE_ERR("Cannot set the dir to %s (%d)\n", wine_dbgstr_w(windowsdir), GetLastError() ); @@ -1160,13 +1161,13 @@ int main( int argc, char *argv[] ) { switch(optc) { - case 'e': end_session = 1; break; - case 'f': force = 1; break; - case 'i': init = 1; break; - case 'k': kill = 1; break; - case 'r': restart = 1; break; - case 's': shutdown = 1; break; - case 'u': update = 1; break; + case 'e': end_session = TRUE; break; + case 'f': force = TRUE; break; + case 'i': init = TRUE; break; + case 'k': kill = TRUE; break; + case 'r': restart = TRUE; break; + case 's': shutdown = TRUE; break; + case 'u': update = TRUE; break; case 'h': usage(); return 0; case '?': usage(); return 1; }