[Asterisk-code-review] astconfigparser: Handle case where line is simply a comment. (asterisk[14])
Joshua Colp
asteriskteam at digium.com
Fri Jul 29 10:35:39 CDT 2016
Joshua Colp has uploaded a new change for review.
https://gerrit.asterisk.org/3375
Change subject: astconfigparser: Handle case where line is simply a comment.
......................................................................
astconfigparser: Handle case where line is simply a comment.
Change-Id: I2dea5815363f4d787d709228a04f33baee383ef5
---
M contrib/scripts/sip_to_pjsip/astconfigparser.py
1 file changed, 3 insertions(+), 0 deletions(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/75/3375/1
diff --git a/contrib/scripts/sip_to_pjsip/astconfigparser.py b/contrib/scripts/sip_to_pjsip/astconfigparser.py
index 46f4fb4..a6d88c7 100644
--- a/contrib/scripts/sip_to_pjsip/astconfigparser.py
+++ b/contrib/scripts/sip_to_pjsip/astconfigparser.py
@@ -203,6 +203,9 @@
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
--
To view, visit https://gerrit.asterisk.org/3375
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2dea5815363f4d787d709228a04f33baee383ef5
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 14
Gerrit-Owner: Joshua Colp <jcolp at digium.com>
More information about the asterisk-code-review
mailing list