DistUpgrade: do not make UI dialog calls while EUID != 0
The screen lock prevention code has to temporarily set the EUID to the non-root user UID so that it can make a DBus call on the user's session bus. While the EUID is temporarily non-zero, a UI dialog may be displayed to report the success of inhibiting the screen lock. For most cases this is OK, but it causes an exception for the DistUpgradeViewKDE frontend. This is because the view.information() call needs to read dialog_error.ui from the tmpdir, but the non-root user does not have permission to read this file. To fix this, in _inhibitIdle(), move the information dialog call to after the finally block which re-sets the EUID.
Loading
Please register or sign in to comment