forked from Mirror/pmbootstrap
Previously, value would sometimes be a string despite the docstring
clearly stating that it should be an integer. This seems to have been a
consequence of literally copying the original C code without considering
that strings work differently between the languages, where the
original assigning a character in a string to an integer results in the
integer having the ASCII value of that character, in Python you just get
the string value of that character. As such, match the original
implementation by explicitly converting from a string to an integer
using ord(), which gives the Unicode code of the provided character.
It is not clear to me why this disparity didn't cause any issues beyond
type errors found by mypy.
See
|
||
---|---|---|
.. | ||
__init__.py | ||
_apkbuild.py | ||
apkindex.py | ||
arguments.py | ||
binfmt_info.py | ||
bootimg.py | ||
cpuinfo.py | ||
depends.py | ||
deviceinfo.py | ||
kconfig.py | ||
kconfigcheck.py | ||
test_apkindex.py | ||
test_bootimg.py | ||
test_deviceinfo.py | ||
version.py |