Switch to unified view

a/libupnpp/upnpplib.cxx b/libupnpp/upnpplib.cxx
...
...
263
    default: return "UPNP UNKNOWN EVENT";
263
    default: return "UPNP UNKNOWN EVENT";
264
    }
264
    }
265
}
265
}
266
266
267
/////////////////////// Small global helpers
267
/////////////////////// Small global helpers
268
268
/** Get rid of white space at both ends */
269
/** Get rid of white space at both ends */
269
void trimstring(string &s, const char *ws)
270
void trimstring(string &s, const char *ws)
270
{
271
{
271
    string::size_type pos = s.find_first_not_of(ws);
272
    string::size_type pos = s.find_first_not_of(ws);
272
    if (pos == string::npos) {
273
    if (pos == string::npos) {
...
...
277
278
278
    pos = s.find_last_not_of(ws);
279
    pos = s.find_last_not_of(ws);
279
    if (pos != string::npos && pos != s.length()-1)
280
    if (pos != string::npos && pos != s.length()-1)
280
        s.replace(pos+1, string::npos, string());
281
        s.replace(pos+1, string::npos, string());
281
}
282
}
283
282
string caturl(const string& s1, const string& s2)
284
string caturl(const string& s1, const string& s2)
283
{
285
{
284
    string out(s1);
286
    string out(s1);
285
    if (out[out.size()-1] == '/') {
287
    if (out[out.size()-1] == '/') {
286
        if (s2[0] == '/')
288
        if (s2[0] == '/')