summaryrefslogtreecommitdiff
path: root/indra/llvfs/llvfile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llvfs/llvfile.cpp')
-rwxr-xr-x[-rw-r--r--]indra/llvfs/llvfile.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/llvfs/llvfile.cpp b/indra/llvfs/llvfile.cpp
index d3f5673485..ed74488af4 100644..100755
--- a/indra/llvfs/llvfile.cpp
+++ b/indra/llvfs/llvfile.cpp
@@ -30,9 +30,10 @@
#include "llerror.h"
#include "llthread.h"
-#include "llvfs.h"
#include "lltimer.h"
#include "llfasttimer.h"
+#include "llmemory.h"
+#include "llvfs.h"
const S32 LLVFile::READ = 0x00000001;
const S32 LLVFile::WRITE = 0x00000002;
@@ -136,12 +137,12 @@ U8* LLVFile::readFile(LLVFS *vfs, const LLUUID &uuid, LLAssetType::EType type, S
}
else
{
- data = new U8[file_size];
+ data = (U8*) ll_aligned_malloc_16(file_size);
file.read(data, file_size); /* Flawfinder: ignore */
if (file.getLastBytesRead() != (S32)file_size)
{
- delete[] data;
+ ll_aligned_free(data);
data = NULL;
file_size = 0;
}