Add a space at end of a config file line that ends with a backslash.

git-svn-id: http://voip.null.ro/svn/yate@2437 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2009-01-14 11:58:18 +00:00
parent 99b135b1f6
commit ed9ddb6234
1 changed files with 3 additions and 4 deletions

View File

@ -244,10 +244,9 @@ bool Configuration::save() const
for (unsigned int i = 0; i < n; i++) {
NamedString *ns = nl->getParam(i);
if (ns) {
const char *v = ns->c_str();
if (!v)
v = "";
::fprintf(f,"%s=%s\n",ns->name().c_str(),v);
// add a space after a line that ends with backslash
const char* bk = ns->endsWith("\\",false) ? " " : "";
::fprintf(f,"%s=%s%s\n",ns->name().safe(),ns->safe(),bk);
}
}
}