From 4b29e9869c52fcba33d40c530eb2fa92648c330e Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Tue, 5 Jul 2016 17:52:01 +0300 Subject: MAINT-5388 File "conversation.log" created in users' root directory on Windows --- indra/llvfs/lldir.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/llvfs') diff --git a/indra/llvfs/lldir.cpp b/indra/llvfs/lldir.cpp index 5f4fb8f4a0..86a15f2ef2 100644 --- a/indra/llvfs/lldir.cpp +++ b/indra/llvfs/lldir.cpp @@ -531,6 +531,13 @@ std::string LLDir::getExpandedFilename(ELLPath location, const std::string& subd case LL_PATH_PER_ACCOUNT_CHAT_LOGS: prefix = getPerAccountChatLogsDir(); + if (prefix.empty()) + { + // potentially directory was not set yet + // intentionally return a blank string to the caller + LL_DEBUGS("LLDir") << "Conversation log directory is not yet set" << LL_ENDL; + return std::string(); + } break; case LL_PATH_LOGS: -- cgit v1.2.3 From cfbc2028ef31f4e4b2a70775f2c330f57108396a Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 14 Nov 2016 20:13:18 +0200 Subject: MAINT-6920 More information in About Second Life floater --- indra/llvfs/llvfs.cpp | 11 +++++++++++ indra/llvfs/llvfs.h | 1 + 2 files changed, 12 insertions(+) (limited to 'indra/llvfs') diff --git a/indra/llvfs/llvfs.cpp b/indra/llvfs/llvfs.cpp index 1cc0e819db..db0eac7031 100644 --- a/indra/llvfs/llvfs.cpp +++ b/indra/llvfs/llvfs.cpp @@ -2114,6 +2114,17 @@ void LLVFS::dumpFiles() LL_INFOS() << "Extracted " << files_extracted << " files out of " << mFileBlocks.size() << LL_ENDL; } +time_t LLVFS::creationTime() +{ + llstat data_file_stat; + int errors = LLFile::stat(mDataFilename, &data_file_stat); + if (0 == errors) + { + return data_file_stat.st_ctime; + } + return 0; +} + //============================================================================ // protected //============================================================================ diff --git a/indra/llvfs/llvfs.h b/indra/llvfs/llvfs.h index 39f31a221b..dca5ff4ad5 100644 --- a/indra/llvfs/llvfs.h +++ b/indra/llvfs/llvfs.h @@ -127,6 +127,7 @@ public: void dumpStatistics(); void listFiles(); void dumpFiles(); + time_t creationTime(); protected: void removeFileBlock(LLVFSFileBlock *fileblock); -- cgit v1.2.3 From 3cf542d81d378112ba98472e8315f0dd9dd4342a Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 15 Dec 2016 09:35:12 -0500 Subject: DRTVWR-418: Store std::string::find() result in size_t, not U32. In a 64-bit build, std::string::npos is way bigger than a U32. --- indra/llvfs/lldir_mac.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llvfs') diff --git a/indra/llvfs/lldir_mac.cpp b/indra/llvfs/lldir_mac.cpp index 4038c92465..30a1ac975e 100644 --- a/indra/llvfs/lldir_mac.cpp +++ b/indra/llvfs/lldir_mac.cpp @@ -94,7 +94,7 @@ LLDir_Mac::LLDir_Mac() // MBW -- This keeps the mac application from finding other things. // If this is really for skins, it should JUST apply to skins. - U32 build_dir_pos = mExecutableDir.rfind("/build-darwin-"); + std::size_t build_dir_pos = mExecutableDir.rfind("/build-darwin-"); if (build_dir_pos != std::string::npos) { // ...we're in a dev checkout -- cgit v1.2.3 From c992a6df9f5c8751c6f4811009e3b1ada09f208e Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 20 Dec 2016 09:20:38 -0500 Subject: DRTVWR-418: std::string::find() returns std::string::size_type. Storing it in a U32 and then comparing it to std::string::npos isn't going to work in 64 bit land. --- indra/llvfs/lldir_mac.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llvfs') diff --git a/indra/llvfs/lldir_mac.cpp b/indra/llvfs/lldir_mac.cpp index 30a1ac975e..e776b84a12 100644 --- a/indra/llvfs/lldir_mac.cpp +++ b/indra/llvfs/lldir_mac.cpp @@ -94,7 +94,7 @@ LLDir_Mac::LLDir_Mac() // MBW -- This keeps the mac application from finding other things. // If this is really for skins, it should JUST apply to skins. - std::size_t build_dir_pos = mExecutableDir.rfind("/build-darwin-"); + std::string::size_type build_dir_pos = mExecutableDir.rfind("/build-darwin-"); if (build_dir_pos != std::string::npos) { // ...we're in a dev checkout -- cgit v1.2.3