From 8644340455a433f4d6e3b31b329479f1e7983f78 Mon Sep 17 00:00:00 2001 From: erik Date: Tue, 23 Jan 2007 21:39:59 +0000 Subject: A couple more return values that need to be checked. --- (limited to 'core') diff --git a/core/opie-login/passworddialogimpl.cpp b/core/opie-login/passworddialogimpl.cpp index d9132e2..3c1b474 100644 --- a/core/opie-login/passworddialogimpl.cpp +++ b/core/opie-login/passworddialogimpl.cpp @@ -164,7 +164,11 @@ void PasswordDialogImpl::writePassword() { ::fclose( file ); ::endpwent(); - ::rename("/etc/passwd.new","/etc/passwd" ); + if (::rename("/etc/passwd.new","/etc/passwd" ) == -1) + return error( tr("Rename /etc/passwd failed"), + tr("Renaming /etc/passwd.new to /etc/passwd failed." + "Please check your /etc/passed file, your /etc directory " + "or your filesystem.") ); /* should be done now */ #ifdef OPIE_LOGIN_SHADOW_PW -- cgit v0.9.0.2