From 0519e2b7e1c6470c67f6755eef3f74023c0ba734 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Mon, 15 Jul 2024 17:03:25 +0200 Subject: [PATCH] osmo-smdpp: Make sure to return empty HTTP response in handleNotification SGP.22 is quite clear in that handleNotification shall return an empty HTTP response body. Let's make sure we comply to that and don't report a JSON response. Change-Id: I1cad539accbc3e7222bfd4780955b3b1ff694c5b --- osmo-smdpp.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/osmo-smdpp.py b/osmo-smdpp.py index 6c275ac7..390db185 100755 --- a/osmo-smdpp.py +++ b/osmo-smdpp.py @@ -186,7 +186,9 @@ class SmDppHttpServer: print("Rx JSON: %s" % json.dumps(content)) set_headers(request) - output = func(self, request, content) or {} + output = func(self, request, content) + if output == None: + return '' build_resp_header(output) print("Tx JSON: %s" % json.dumps(output))