From c3909170e8e54ed7422a635406976311168a9f76 Mon Sep 17 00:00:00 2001 From: Davis King Date: Sun, 16 Jun 2013 12:07:32 -0400 Subject: [PATCH] updated example --- examples/dir_nav_ex.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/examples/dir_nav_ex.cpp b/examples/dir_nav_ex.cpp index fa81ca16f..2f51f2d1b 100644 --- a/examples/dir_nav_ex.cpp +++ b/examples/dir_nav_ex.cpp @@ -30,16 +30,14 @@ int main(int argc, char** argv) directory test(loc); - std::vector dirs; - std::vector files; cout << "directory: " << test.name() << endl; cout << "full path: " << test.full_name() << endl; cout << "is root: " << ((test.is_root())?"yes":"no") << endl; // get all directories and files in test - test.get_dirs(dirs); - test.get_files(files); + std::vector dirs = test.get_dirs(); + std::vector files = test.get_files(); // sort the files and directories sort(files.begin(), files.end());