From b46c0ed1fa07698297d5cf645b97a1978092868d Mon Sep 17 00:00:00 2001 From: Lioncash Date: Fri, 20 Jul 2018 22:30:20 -0400 Subject: vfs_real: Remove redundant copying of std::vector instances in GetFiles() and GetSubdirectories() We already return by value, so we don't explicitly need to make the copy. --- src/core/file_sys/vfs_real.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/core/file_sys/vfs_real.cpp b/src/core/file_sys/vfs_real.cpp index 8df6e97ef..f27fb1f2a 100644 --- a/src/core/file_sys/vfs_real.cpp +++ b/src/core/file_sys/vfs_real.cpp @@ -3,6 +3,7 @@ // Refer to the license.txt file included. #include +#include #include #include @@ -108,11 +109,11 @@ RealVfsDirectory::RealVfsDirectory(const std::string& path_, Mode perms_) } std::vector> RealVfsDirectory::GetFiles() const { - return std::vector>(files); + return files; } std::vector> RealVfsDirectory::GetSubdirectories() const { - return std::vector>(subdirectories); + return subdirectories; } bool RealVfsDirectory::IsWritable() const { -- cgit v1.2.3