about summary refs log tree commit diff
path: root/src/libutil/util.cc
diff options
context:
space:
mode:
authorAndy Wingo <wingo@igalia.com>2017-08-18T09·07+0200
committerAndy Wingo <wingo@igalia.com>2017-08-18T09·07+0200
commit6bb4e3e8fe30a09d174a04295ba074ee006ebb4f (patch)
treec0a7797bba12e237ed5643c066fe50b51b357872 /src/libutil/util.cc
parente2f9a61dc95f8f0ee51995ad88f4c5d5bd0e7740 (diff)
Remove unused decodeOctalEscaped
Besides being unused, this function has a bug that it will incorrectly
decode the path component Ubuntu\04016.04.2\040LTS\040amd64 as
"Ubuntu.04.2 LTS amd64" instead of "Ubuntu 16.04.2 LTS amd64".
Diffstat (limited to 'src/libutil/util.cc')
-rw-r--r--src/libutil/util.cc15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/libutil/util.cc b/src/libutil/util.cc
index 55d3e1d16f6c..c2bceea3d9d0 100644
--- a/src/libutil/util.cc
+++ b/src/libutil/util.cc
@@ -1140,21 +1140,6 @@ std::string toLower(const std::string & s)
 }
 
 
-string decodeOctalEscaped(const string & s)
-{
-    string r;
-    for (string::const_iterator i = s.begin(); i != s.end(); ) {
-        if (*i != '\\') { r += *i++; continue; }
-        unsigned char c = 0;
-        ++i;
-        while (i != s.end() && *i >= '0' && *i < '8')
-            c = c * 8 + (*i++ - '0');
-        r += c;
-    }
-    return r;
-}
-
-
 void ignoreException()
 {
     try {