open() function does not support setting file permissions #824

Closed
wants to merge 1 commit into
from

Projects

None yet

3 participants

@JohnVillalovos

The open() function does not support setting file permissions[1]. The
code was setting the buffer to 0o600. Remove the attempted file
permission value.

[1] https://docs.python.org/2/library/functions.html#open

Change-Id: I582e226f8bc76e877c7da686f36e2efa33f0d24f

John L. Villalovos open() function does not support setting file permissions
The open() function does not support setting file permissions[1]. The
code was setting the buffer to 0o600. Remove the attempted file
permission value.

[1] https://docs.python.org/2/library/functions.html#open

Change-Id: I582e226f8bc76e877c7da686f36e2efa33f0d24f
bf04ec2
@coveralls
coveralls commented Oct 6, 2016 edited

Coverage Status

Coverage increased (+0.01%) to 74.22% when pulling bf04ec2 on JohnVillalovos:master into 7366f96 on paramiko:master.

@coveralls
coveralls commented Oct 6, 2016 edited

Coverage Status

Coverage increased (+0.01%) to 74.22% when pulling bf04ec2 on JohnVillalovos:master into 7366f96 on paramiko:master.

@bitprophet
Member

Bizarre, as far as I can tell that should never have been correct, e.g. I spot checked Python 2.2 (Paramiko dates back that far) and it's the same signature as now, unsurprisingly.

Seems this has been in since the beginning (01bf547) and nobody ever noticed because it doesn't cause exceptions (that, and this method isn't called terrifically often by most users).

Thanks for the catch!

@bitprophet bitprophet added this to the 1.16.4 et al milestone Oct 7, 2016
@JohnVillalovos

You're welcome. Glad to help!

@bitprophet bitprophet added a commit that referenced this pull request Dec 6, 2016
@bitprophet bitprophet Changelog re #824 8447903
@bitprophet
Member

Cherry-picked to 1.17.

@bitprophet bitprophet closed this Dec 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment