-rw-r--r-- | core/opie-login/main.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/opie-login/main.cpp b/core/opie-login/main.cpp index 5ecde1e..7d2ed63 100644 --- a/core/opie-login/main.cpp +++ b/core/opie-login/main.cpp @@ -170,56 +170,57 @@ int main ( int argc, char **argv ) const char *sig = ::strsignal ( killedbysig ); QLabel *l = new QLabel ( 0, "sig", Qt::WStyle_Customize | Qt::WStyle_NoBorder | Qt::WStyle_Tool ); l-> setText ( LoginWindowImpl::tr( "Opie was terminated\nby an uncaught signal\n(%1)\n" ). arg ( sig )); l-> setAlignment ( Qt::AlignCenter ); l-> move ( 0, 0 ); l-> resize ( app-> desktop ( )-> width ( ), app-> desktop ( )-> height ( )); l-> show ( ); QTimer::singleShot ( 3000, app, SLOT( quit ( ))); app-> exec ( ); delete app; qApp = 0; } } else { if ( !autolog ) { QString confFile=QPEApplication::qpeDir() + "/etc/opie-login.conf"; Config cfg ( confFile, Config::File ); cfg. setGroup ( "General" ); QString user = cfg. readEntry ( "AutoLogin" ); if ( !user. isEmpty ( )) autolog = ::strdup ( user. latin1 ( )); } - + if ( autolog && !userExited ) { QWSServer::setDesktopBackground( QImage() ); ODevice::inst ( )-> setDisplayStatus ( true ); ODevice::inst ( )-> setSoftSuspend ( false ); LoginApplication *app = new LoginApplication ( argc, argv, ppid ); LoginApplication::setLoginAs ( autolog ); + if ( LoginApplication::changeIdentity ( )) ::exit ( LoginApplication::login ( )); else ::exit ( 0 ); } else { ::exit ( login_main ( argc, argv, ppid )); } } } return 0; } void sigterm ( int /*sig*/ ) { ::exit ( 0 ); } void exit_closelog ( ) { ::closelog ( ); } |