summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/contrib')
-rw-r--r--apt-pkg/contrib/strutl.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc
index 5e641a02b..242a78449 100644
--- a/apt-pkg/contrib/strutl.cc
+++ b/apt-pkg/contrib/strutl.cc
@@ -464,7 +464,9 @@ string SubstVar(const string &Str,const string &Subst,const string &Contents)
if (OldPos >= Str.length())
return Temp;
- return Temp + string(Str,OldPos);
+
+ Temp.append(Str, OldPos, string::npos);
+ return Temp;
}
string SubstVar(string Str,const struct SubstVar *Vars)
{