[sr-dev] git:master:f68cbc16: core: ppcfg - skip ending quite for exported defined values to snexpr
Daniel-Constantin Mierla
miconda at gmail.com
Wed Sep 14 18:32:10 CEST 2022
Module: kamailio
Branch: master
Commit: f68cbc16b7ac29cce143f7b77114eaef37312ab6
URL: https://github.com/kamailio/kamailio/commit/f68cbc16b7ac29cce143f7b77114eaef37312ab6
Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2022-09-14T18:31:59+02:00
core: ppcfg - skip ending quite for exported defined values to snexpr
---
Modified: src/core/ppcfg.c
---
Diff: https://github.com/kamailio/kamailio/commit/f68cbc16b7ac29cce143f7b77114eaef37312ab6.diff
Patch: https://github.com/kamailio/kamailio/commit/f68cbc16b7ac29cce143f7b77114eaef37312ab6.patch
---
diff --git a/src/core/ppcfg.c b/src/core/ppcfg.c
index 895855df38..fc570faecd 100644
--- a/src/core/ppcfg.c
+++ b/src/core/ppcfg.c
@@ -393,7 +393,7 @@ static struct snexpr* pp_snexpr_defval(char *vname)
if(pd->value.len>=2 && (pd->value.s[0]=='"' || pd->value.s[0]=='\'')
&& pd->value.s[0]==pd->value.s[pd->value.len-1]) {
/* strip enclosing quotes for string value */
- return snexpr_convert_stzl(pd->value.s+1, pd->value.len-1, SNE_OP_CONSTSTZ);
+ return snexpr_convert_stzl(pd->value.s+1, pd->value.len-2, SNE_OP_CONSTSTZ);
} else {
return snexpr_convert_stzl(pd->value.s, pd->value.len, SNE_OP_CONSTSTZ);
}
More information about the sr-dev
mailing list