Skip to content

Commit

Permalink
windows: sanitize_line() compatibility
Browse files Browse the repository at this point in the history
Signed-off-by: Rafał Wojdyła <[email protected]>
  • Loading branch information
omeg committed Feb 26, 2025
1 parent f1f0a9d commit a23caaf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion qubesbuilder/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,10 @@ def sanitize_line(untrusted_line: bytes):
if 0x20 <= c <= 0x7E:
pass
else:
line[i] = 0x2E
if c == 0x0D: # windows newline
line[i] = 0x20
else:
line[i] = 0x2E
return bytearray(line).decode("ascii")


Expand Down

0 comments on commit a23caaf

Please sign in to comment.