aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJisi Liu <jisi.liu@gmail.com>2017-09-27 10:33:04 -0700
committerJisi Liu <jisi.liu@gmail.com>2017-09-27 10:33:04 -0700
commit5a501c64c7b448a025d3107379e8d1cf2287d18e (patch)
tree7f6d6a287ddfba03969514a5c819c6723abc60dd /src
parent655cc830d9a22022e89fffdf11ed3cc206e0852c (diff)
downloadprotobuf-5a501c64c7b448a025d3107379e8d1cf2287d18e.tar.gz
protobuf-5a501c64c7b448a025d3107379e8d1cf2287d18e.tar.bz2
protobuf-5a501c64c7b448a025d3107379e8d1cf2287d18e.zip
Fix C++11 string accessors
Diffstat (limited to 'src')
-rw-r--r--src/google/protobuf/testing/file.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/google/protobuf/testing/file.cc b/src/google/protobuf/testing/file.cc
index f32222b7..b9cfe8be 100644
--- a/src/google/protobuf/testing/file.cc
+++ b/src/google/protobuf/testing/file.cc
@@ -121,7 +121,7 @@ void File::WriteStringToFileOrDie(const string& contents, const string& name) {
bool File::CreateDir(const string& name, int mode) {
if (!name.empty()) {
- GOOGLE_CHECK_OK(name.back() != '.');
+ GOOGLE_CHECK_OK(name[name.size()-1] != '.');
}
return mkdir(name.c_str(), mode) == 0;
}