Do not clear DISPLAY variable unconditionally#807
Open
mruprich wants to merge 1 commit intoRsyncProject:masterfrom
Open
Do not clear DISPLAY variable unconditionally#807mruprich wants to merge 1 commit intoRsyncProject:masterfrom
mruprich wants to merge 1 commit intoRsyncProject:masterfrom
Conversation
Contributor
Author
|
Another solution here would be to simply revert the original fix. The initial problem and hang was in dbus, not rsync. Seems to me like the bugfix solved one particular usecase of dbus bug but I don't think it justifies this being in rsync forever. |
Contributor
Author
|
Hello, any update with this PR? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
A while ago as a reaction to this bug - #176 - rsync started clearing the DISPLAY env variable during start-up. rsync has no knowledge of the use of DISPLAY in the system so it should not clear the variable unconditionally. The unconditional clearing of the variable breaks the usage of SSH_ASKPASS for instance:
SSH_ASKPASS If ssh needs a passphrase, it will read the passphrase from the current terminal if it was run from a terminal. If ssh does not have a terminal associated with it but DISPLAY and SSH_ASKPASS are set, it will execute the program specified by SSH_ASKPASS and open an X11 window to read the passphrase. This is particularly useful when calling ssh from a .xsession or related script. (Note that on some machines it may be necessary to redirect the input from /dev/null to make this work.)
Clearing DISPLAY breaks the usage of the above ssh option. rsync should not assume that DISPLAY should be cleared every time. Simple reproducer in Fedora on a single machine below: