summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2016-07-29 06:48:32 -0300
committerJoshua Colp <jcolp@digium.com>2016-07-29 04:49:06 -0500
commita7ae48441fe7027ff3d6a92b660cec51f9fe4030 (patch)
tree12ec6c8e77904c567f2c269331ea674ad899ece2 /contrib
parent6131d70aa8aebf73c073ff57e05a0d1b247b0906 (diff)
astconfigparser: Handle case where line is simply a comment.
Change-Id: I2dea5815363f4d787d709228a04f33baee383ef5
Diffstat (limited to 'contrib')
-rw-r--r--contrib/scripts/sip_to_pjsip/astconfigparser.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/contrib/scripts/sip_to_pjsip/astconfigparser.py b/contrib/scripts/sip_to_pjsip/astconfigparser.py
index 46f4fb484..a6d88c7b7 100644
--- a/contrib/scripts/sip_to_pjsip/astconfigparser.py
+++ b/contrib/scripts/sip_to_pjsip/astconfigparser.py
@@ -203,6 +203,9 @@ def remove_comment(line, is_comment):
if match:
# the end of where the real string is is where the comment starts
line = line[0:(match.end()-1)]
+ elif line.startswith(";"):
+ # if the line is actually a comment just ignore it all
+ line = ""
return line.replace("\\", "").strip(), False