summaryrefslogtreecommitdiff
path: root/indra/llvfs
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llvfs')
-rw-r--r--indra/llvfs/CMakeLists.txt28
-rw-r--r--indra/llvfs/lldir_mac.cpp32
-rw-r--r--indra/llvfs/lldir_mac.h1
-rw-r--r--indra/llvfs/lldiriterator.cpp4
-rw-r--r--indra/llvfs/llvfile.cpp4
-rw-r--r--indra/llvfs/llvfs.cpp3
6 files changed, 21 insertions, 51 deletions
diff --git a/indra/llvfs/CMakeLists.txt b/indra/llvfs/CMakeLists.txt
index a3782d824b..b6d1ce61e5 100644
--- a/indra/llvfs/CMakeLists.txt
+++ b/indra/llvfs/CMakeLists.txt
@@ -74,17 +74,17 @@ if (DARWIN)
endif (DARWIN)
-if(LL_TESTS)
- # Add tests
- include(LLAddBuildTest)
- # UNIT TESTS
- SET(llvfs_TEST_SOURCE_FILES
- # none so far
- )
- LL_ADD_PROJECT_UNIT_TESTS(llvfs "${llvfs_TEST_SOURCE_FILES}")
-
- # INTEGRATION TESTS
- set(test_libs llmath llcommon llvfs ${LLCOMMON_LIBRARIES} ${WINDOWS_LIBRARIES})
- # TODO: Some of these need refactoring to be proper Unit tests rather than Integration tests.
- LL_ADD_INTEGRATION_TEST(lldir "" "${test_libs}")
-endif(LL_TESTS)
+# Add tests
+if (LL_TESTS)
+ include(LLAddBuildTest)
+ # UNIT TESTS
+ SET(llvfs_TEST_SOURCE_FILES
+ # none so far
+ )
+ LL_ADD_PROJECT_UNIT_TESTS(llvfs "${llvfs_TEST_SOURCE_FILES}")
+
+ # INTEGRATION TESTS
+ set(test_libs llmath llcommon llvfs ${LLCOMMON_LIBRARIES} ${WINDOWS_LIBRARIES})
+ # TODO: Some of these need refactoring to be proper Unit tests rather than Integration tests.
+ LL_ADD_INTEGRATION_TEST(lldir "" "${test_libs}")
+endif (LL_TESTS)
diff --git a/indra/llvfs/lldir_mac.cpp b/indra/llvfs/lldir_mac.cpp
index 8f48f92e2a..489bc3e4a7 100644
--- a/indra/llvfs/lldir_mac.cpp
+++ b/indra/llvfs/lldir_mac.cpp
@@ -258,38 +258,6 @@ U32 LLDir_Mac::countFilesInDir(const std::string &dirname, const std::string &ma
return (file_count);
}
-S32 LLDir_Mac::deleteFilesInDir(const std::string &dirname, const std::string &mask)
-{
- glob_t g;
- S32 result = 0;
-
- std::string tmp_str;
- tmp_str = dirname;
- tmp_str += mask;
-
- if(glob(tmp_str.c_str(), GLOB_NOSORT, NULL, &g) == 0)
- {
- int i;
-
- for(i = 0; i < g.gl_pathc; i++)
- {
-// llinfos << "deleteFilesInDir: deleting number " << i << ", path is " << g.gl_pathv[i] << llendl;
-
- if(unlink(g.gl_pathv[i]) != 0)
- {
- result = errno;
-
- llwarns << "Problem removing " << g.gl_pathv[i] << " - errorcode: "
- << result << llendl;
- }
- }
-
- globfree(&g);
- }
-
- return(result);
-}
-
std::string LLDir_Mac::getCurPath()
{
char tmp_str[LL_MAX_PATH]; /* Flawfinder: ignore */
diff --git a/indra/llvfs/lldir_mac.h b/indra/llvfs/lldir_mac.h
index bc3f0fac00..d190d70be4 100644
--- a/indra/llvfs/lldir_mac.h
+++ b/indra/llvfs/lldir_mac.h
@@ -44,7 +44,6 @@ public:
/*virtual*/ void initAppDirs(const std::string &app_name,
const std::string& app_read_only_data_dir);
- virtual S32 deleteFilesInDir(const std::string &dirname, const std::string &mask);
virtual std::string getCurPath();
virtual U32 countFilesInDir(const std::string &dirname, const std::string &mask);
virtual BOOL fileExists(const std::string &filename) const;
diff --git a/indra/llvfs/lldiriterator.cpp b/indra/llvfs/lldiriterator.cpp
index 5536ed8f69..041436ed92 100644
--- a/indra/llvfs/lldiriterator.cpp
+++ b/indra/llvfs/lldiriterator.cpp
@@ -55,7 +55,7 @@ LLDirIterator::Impl::Impl(const std::string &dirname, const std::string &mask)
// Check if path exists.
if (!fs::exists(dir_path))
{
- llerrs << "Invalid path: \"" << dir_path.string() << "\"" << llendl;
+ llwarns << "Invalid path: \"" << dir_path.string() << "\"" << llendl;
return;
}
@@ -100,7 +100,7 @@ bool LLDirIterator::Impl::next(std::string &fname)
if (!mIsValid)
{
- llerrs << "The iterator is not correctly initialized." << llendl;
+ llwarns << "The iterator is not correctly initialized." << llendl;
return false;
}
diff --git a/indra/llvfs/llvfile.cpp b/indra/llvfs/llvfile.cpp
index a8db7b235e..ca749c5eaf 100644
--- a/indra/llvfs/llvfile.cpp
+++ b/indra/llvfs/llvfile.cpp
@@ -314,7 +314,7 @@ BOOL LLVFile::setMaxSize(S32 size)
if (!mVFS->checkAvailable(size))
{
- LLFastTimer t(FTM_VFILE_WAIT);
+ //LLFastTimer t(FTM_VFILE_WAIT);
S32 count = 0;
while (sVFSThread->getPending() > 1000)
{
@@ -422,7 +422,7 @@ bool LLVFile::isLocked(EVFSLock lock)
void LLVFile::waitForLock(EVFSLock lock)
{
- LLFastTimer t(FTM_VFILE_WAIT);
+ //LLFastTimer t(FTM_VFILE_WAIT);
// spin until the lock clears
while (isLocked(lock))
{
diff --git a/indra/llvfs/llvfs.cpp b/indra/llvfs/llvfs.cpp
index 78b67e9b68..82c926620a 100644
--- a/indra/llvfs/llvfs.cpp
+++ b/indra/llvfs/llvfs.cpp
@@ -2036,6 +2036,9 @@ std::string get_extension(LLAssetType::EType type)
case LLAssetType::AT_ANIMATION:
extension = ".lla";
break;
+ case LLAssetType::AT_MESH:
+ extension = ".slm";
+ break;
default:
// Just use the asset server filename extension in most cases
extension += ".";