fix IndexError: list index out of range in sdr input routine (pocsagDecoder) #111

This commit is contained in:
Bastian Schroll 2025-06-11 08:33:09 +00:00 committed by GitHub
parent d4e9b631ab
commit dc052b94f4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -40,7 +40,7 @@ class PocsagDecoder:
if re.search("[0-9]{7}", ric) and re.search("[1-4]", subric):
if "Alpha:" in data:
message = data.split('Alpha: ')[1].strip()
message = data.split('Alpha:')[1].strip()
message = message.replace('<NUL>', '').replace('<NUL', '').replace('< NUL>', '').replace('<EOT>', '').strip()
else:
message = ""