Patch Set 1: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/5028/1/osmopy/osmo_ipa.py
File osmopy/osmo_ipa.py:

Line 241:         if s == self.CTRL_ERR:
so you are splitting bytes into smaller bytes, then you go on to compare 
against string constants ... Instead, you may want to do

  data_str = data.decode('utf-8')

If we're allowing arbitrary bytes in the value, you want to do the decode step 
after the split... But there should be some decode step *somewhere*. I wonder 
why this alone seems to be working for you, it should still cause encoding 
problems.


-- 
To view, visit https://gerrit.osmocom.org/5028
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I599f9f5a18109929f59386ab4416b8bfd75c74d1
Gerrit-PatchSet: 1
Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-Owner: Max <[email protected]>
Gerrit-Reviewer: Neels Hofmeyr <[email protected]>
Gerrit-HasComments: Yes

Reply via email to