From c54b7c1ec4f04fd65d2a1f54202fd34517bba980 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 27 May 2014 21:53:29 -0400 Subject: [PATCH] Get rid of unnecessary c_str calls in VirtualDiscFileSystem.cpp --- Core/FileSystems/VirtualDiscFileSystem.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Core/FileSystems/VirtualDiscFileSystem.cpp b/Core/FileSystems/VirtualDiscFileSystem.cpp index 75da23a191..17443358ef 100644 --- a/Core/FileSystems/VirtualDiscFileSystem.cpp +++ b/Core/FileSystems/VirtualDiscFileSystem.cpp @@ -105,7 +105,7 @@ void VirtualDiscFileSystem::LoadFileListIndex() { size_t handler_pos = line.find(':', filename_pos); if (handler_pos != line.npos) { entry.fileName = line.substr(filename_pos + 1, handler_pos - filename_pos - 1); - std::string handler = line.substr(handler_pos + 1).c_str(); + std::string handler = line.substr(handler_pos + 1); size_t trunc = handler.find_last_not_of("\r\n"); if (trunc != handler.npos && trunc != handler.size()) handler.resize(trunc + 1); @@ -113,7 +113,7 @@ void VirtualDiscFileSystem::LoadFileListIndex() { handlers[handler] = new Handler(handler.c_str(), this); entry.handler = handlers[handler]; } else { - entry.fileName = line.substr(filename_pos + 1).c_str(); + entry.fileName = line.substr(filename_pos + 1); } size_t trunc = entry.fileName.find_last_not_of("\r\n"); if (trunc != entry.fileName.npos && trunc != entry.fileName.size())