From b1bcb2e798d6827d4c94367322c2df85c2f7f013 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Mon, 18 Jun 2012 18:41:08 +0000 Subject: [PATCH] copy leftover chars even if no escapes are present --- modules/dialplan/dp_repl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/dialplan/dp_repl.c b/modules/dialplan/dp_repl.c index 874d526e1..6a365c88e 100644 --- a/modules/dialplan/dp_repl.c +++ b/modules/dialplan/dp_repl.c @@ -292,7 +292,7 @@ int rule_translate(struct sip_msg *msg, str string, dpl_node_t * rule, repl_nb++; } /* anything left? */ - if( repl_nb && offset < repl_comp->replacement.len){ + if(offset < repl_comp->replacement.len){ /*copy from the replacing string*/ size = repl_comp->replacement.len - offset; memcpy(result->s + result->len, p + offset, size);