diff options
Diffstat (limited to 'scripts/cxxdemo')
-rw-r--r-- | scripts/cxxdemo/hex8tohex32.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/scripts/cxxdemo/hex8tohex32.py b/scripts/cxxdemo/hex8tohex32.py index 3fa80b1..ae44101 100644 --- a/scripts/cxxdemo/hex8tohex32.py +++ b/scripts/cxxdemo/hex8tohex32.py @@ -25,9 +25,8 @@ for line in fileinput.input(): data.append(0) ptr -= 1 else: - while ptr < addr: + while ptr + len(data) < addr: data.append(0) - ptr += 1 else: data += [int(tok, 16) for tok in line.split()] |