-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Minor change to sshkey_paramiko.r2py. Replaced decode() with decode_next() #192
base: master
Are you sure you want to change the base?
Conversation
replaced unsafe 'decode' call with 'decode_next'
@@ -94,9 +94,6 @@ class _sshkey_paramiko_BER(object): | |||
def __init__(self, content=''): | |||
self.content = content | |||
self.idx = 0 | |||
|
|||
def decode(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it makes sense to add a comment to explain why you changed this. The reason is that at some point in the future, if we want to re-port the Paramiko library, we should know why this edit was done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the comment. I added a simple explanation to where the decode function was. Is this okay?
sshkey_paramiko.r2py
Outdated
def decode(self): | ||
return self.decode_next() | ||
|
||
# June 27, 2017: removed decode function, as it is not allowed by safe.py |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. (The Git metadata contains the date however, so there's no real need to add it to the comment.)
This just shows whether all non-UT RepyV2 files in this dir can be put into a VirtualNamespace without errors. If provided as a SeattleTestbed/seattlelib_v2 unit test, it would have caught SeattleTestbed/seattlelib_v2#192 easily. Note: This script doesn't provide `dylink` functions or the actual RepyV2 API to the checked libraries yet!
Replaced the decode() function calls with decode_next(), since decode is not allowed for safety reasons.
See the relevant repyV1 commit that introduced that safety check:
SeattleTestbed/repy_v1@bc6b6b9
Also, the same changes made to sshkey_paramiko.repy:
SeattleTestbed/seattlelib_v1@2d1262e?diff=unified