Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #73.
The problem and solution are also explained here: https://bbs.archlinux.org/viewtopic.php?id=267747, and something very similar happened in #57 as well.
To summarise, there is a polkit rule in com.ubuntu.pkexec.gufw.policy which points to
/usr/bin/gufw-pkexec
.The gufw script called
gufw-pkexec
without specifying its full path, which caused issues.#57 fixed it by replacing the call with
$(which gufw-pkexec)
.However, this can resolve to other paths, like
/sbin/gufw-pkexec
, which is a link to/usr/bin/gufw-pkexec
, so it crashes.This is why
readlink -f
has to be used to always point to the original,/usr/bin/gufw-pkexec
path.As an alternative you could just add
/usr/bin/gufw-pkexec
to avoid these commands, as it is already expected that they will resolve to that.