From: liuyuhong Date: Thu, 27 Apr 2017 08:48:57 +0000 (+0800) Subject: rgw/rgw_swift_auth.cc: using string::back() instead as the C++11 recommend X-Git-Tag: v12.1.0~10^2~42^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ed44687a79e06e893d67c32ae842d13a046904cc;p=ceph.git rgw/rgw_swift_auth.cc: using string::back() instead as the C++11 recommend Signed-off-by: liuyuhong --- diff --git a/src/rgw/rgw_swift_auth.cc b/src/rgw/rgw_swift_auth.cc index cc26db4fcce5..196d1988e018 100644 --- a/src/rgw/rgw_swift_auth.cc +++ b/src/rgw/rgw_swift_auth.cc @@ -304,7 +304,7 @@ ExternalTokenEngine::authenticate(const std::string& token, } std::string auth_url = g_conf->rgw_swift_auth_url; - if (auth_url[auth_url.length() - 1] != '/') { + if (auth_url.back() != '/') { auth_url.append("/"); }