Commit 756934bc authored by NiranV's avatar NiranV
Browse files

Merge with Linden Release.

--HG--
branch : Black Dragon
parents 753bf8b3 d656d49a
......@@ -556,6 +556,7 @@ ece699718f163921717bb95a6131e94af4c4138f 6.3.1-release
07f5d5bc9faebb45695853d40a9549773db816c0 6.3.2-release
d9a4bd15e2c852953d6c8e84d6f3b7ca442c0e7f 6.3.3-release
4033b3f57e76f087235145a3016886ccdc87ffa3 6.3.4-release
27ca5834bfe9b80e82db5ea42f08b7eb990b722a 6.3.5-release
0000000000000000000000000000000000000000 v2start
0000000000000000000000000000000000000000 alpha-3
0000000000000000000000000000000000000000 fork to viewer-2-0
......
......@@ -3226,9 +3226,9 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>archive</key>
<map>
<key>hash</key>
<string>42066e2447c7a3359784438d16510992</string>
<string>c5ab9d9d7482e48cd76f4bf391900a8c</string>
<key>url</key>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/40539/348124/viewer_manager-2.0.529188-darwin64-529188.tar.bz2</string>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/43369/385585/viewer_manager-2.0.531000-darwin64-531000.tar.bz2</string>
</map>
<key>name</key>
<string>darwin64</string>
......@@ -3250,9 +3250,9 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>archive</key>
<map>
<key>hash</key>
<string>ca230428635ce13cb7ace0f9522f8546</string>
<string>6b10d7407686d9e12e63576256581e3e</string>
<key>url</key>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/40538/348130/viewer_manager-2.0.529188-windows-529188.tar.bz2</string>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/43370/385592/viewer_manager-2.0.531000-windows-531000.tar.bz2</string>
</map>
<key>name</key>
<string>windows</string>
......@@ -3263,7 +3263,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>source_type</key>
<string>hg</string>
<key>version</key>
<string>2.0.529188</string>
<string>2.0.531000</string>
</map>
<key>vlc-bin</key>
<map>
......
......@@ -186,12 +186,17 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
list(GET LL_BUILD_LIST "${sysroot_idx}" CMAKE_OSX_SYSROOT)
message(STATUS "CMAKE_OSX_SYSROOT = '${CMAKE_OSX_SYSROOT}'")
set(XCODE_VERSION 7.0)
set(CMAKE_XCODE_ATTRIBUTE_GCC_VERSION "com.apple.compilers.llvm.clang.1_0")
set(CMAKE_XCODE_ATTRIBUTE_GCC_STRICT_ALIASING NO)
set(CMAKE_XCODE_ATTRIBUTE_GCC_FAST_MATH NO)
set(CMAKE_XCODE_ATTRIBUTE_CLANG_X86_VECTOR_INSTRUCTIONS ssse3)
# we must hard code this to off for now. xcode's built in signing does not
# handle embedded app bundles such as CEF and others. Any signing for local
# development must be done after the build as we do in viewer_manifest.py for
# released builds
# https://stackoverflow.com/a/54296008
# "-" represents "Sign to Run Locally" and empty string represents "Do Not Sign"
set(CMAKE_XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "")
set(CMAKE_OSX_ARCHITECTURES "${ARCH}")
string(REPLACE "i686" "i386" CMAKE_OSX_ARCHITECTURES "${CMAKE_OSX_ARCHITECTURES}")
......
......@@ -107,11 +107,11 @@ BOOL LLGesture::trigger(const std::string& trigger_string)
// NOT endian-neutral
U8 *LLGesture::serialize(U8 *buffer) const
{
htonmemcpy(buffer, &mKey, MVT_S8, 1);
htolememcpy(buffer, &mKey, MVT_S8, 1);
buffer += sizeof(mKey);
htonmemcpy(buffer, &mMask, MVT_U32, 4);
htolememcpy(buffer, &mMask, MVT_U32, 4);
buffer += sizeof(mMask);
htonmemcpy(buffer, mSoundItemID.mData, MVT_LLUUID, 16);
htolememcpy(buffer, mSoundItemID.mData, MVT_LLUUID, 16);
buffer += 16;
memcpy(buffer, mTrigger.c_str(), mTrigger.length() + 1); /* Flawfinder: ignore */
......@@ -134,11 +134,11 @@ U8 *LLGesture::deserialize(U8 *buffer, S32 max_size)
return buffer;
}
htonmemcpy(&mKey, tmp, MVT_S8, 1);
htolememcpy(&mKey, tmp, MVT_S8, 1);
tmp += sizeof(mKey);
htonmemcpy(&mMask, tmp, MVT_U32, 4);
htolememcpy(&mMask, tmp, MVT_U32, 4);
tmp += sizeof(mMask);
htonmemcpy(mSoundItemID.mData, tmp, MVT_LLUUID, 16);
htolememcpy(mSoundItemID.mData, tmp, MVT_LLUUID, 16);
tmp += 16;
mTrigger.assign((char *)tmp);
......@@ -284,7 +284,7 @@ U8 *LLGestureList::serialize(U8 *buffer) const
{
// a single S32 serves as the header that tells us how many to read
U32 count = mList.size();
htonmemcpy(buffer, &count, MVT_S32, 4);
htolememcpy(buffer, &count, MVT_S32, 4);
buffer += sizeof(count);
for (S32 i = 0; i < count; i++)
......@@ -310,7 +310,7 @@ U8 *LLGestureList::deserialize(U8 *buffer, S32 max_size)
return buffer;
}
htonmemcpy(&count, tmp, MVT_S32, 4);
htolememcpy(&count, tmp, MVT_S32, 4);
if (count > MAX_GESTURES)
{
......
......@@ -347,7 +347,7 @@ void LLCoros::toplevel(coro::self& self, CoroData* data, const callable_t& calla
// run the code the caller actually wants in the coroutine
try
{
#if LL_WINDOWS
#if LL_WINDOWS && LL_RELEASE_FOR_DOWNLOAD
winlevel(callable);
#else
callable();
......
......@@ -2168,19 +2168,27 @@ bool LLImageFormatted::load(const std::string &filename, int load_size)
}
bool res;
U8 *data = allocateData(load_size);
apr_size_t bytes_read = load_size;
apr_status_t s = apr_file_read(apr_file, data, &bytes_read); // modifies bytes_read
if (s != APR_SUCCESS || (S32) bytes_read != load_size)
if (data)
{
deleteData();
setLastError("Unable to read file",filename);
res = false;
apr_size_t bytes_read = load_size;
apr_status_t s = apr_file_read(apr_file, data, &bytes_read); // modifies bytes_read
if (s != APR_SUCCESS || (S32) bytes_read != load_size)
{
deleteData();
setLastError("Unable to read file",filename);
res = false;
}
else
{
res = updateData();
}
}
else
{
res = updateData();
setLastError("Allocation failure", filename);
res = false;
}
return res;
}
......
......@@ -2421,7 +2421,7 @@ bool LLVolume::unpackVolumeFaces(std::istream& is, S32 size)
if (idx.empty() || face.mNumIndices < 3)
{ //why is there an empty index list?
LL_WARNS() <<"Empty face present!" << LL_ENDL;
LL_WARNS() << "Empty face present! Face index: " << i << " Total: " << face_count << LL_ENDL;
continue;
}
......@@ -5265,7 +5265,7 @@ bool LLVolumeFace::cacheOptimize()
LLVCacheLRU cache;
if (mNumVertices < 3)
if (mNumVertices < 3 || mNumIndices < 3)
{ //nothing to do
return true;
}
......
......@@ -186,7 +186,7 @@ BOOL LLDataPackerBinaryBuffer::packString(const std::string& value, const char *
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.c_str(), MVT_VARIABLE, length);
htolememcpy(mCurBufferp, value.c_str(), MVT_VARIABLE, length);
}
mCurBufferp += length;
return success;
......@@ -213,12 +213,12 @@ BOOL LLDataPackerBinaryBuffer::packBinaryData(const U8 *value, S32 size, const c
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &size, MVT_S32, 4);
htolememcpy(mCurBufferp, &size, MVT_S32, 4);
}
mCurBufferp += 4;
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value, MVT_VARIABLE, size);
htolememcpy(mCurBufferp, value, MVT_VARIABLE, size);
}
mCurBufferp += size;
return success;
......@@ -229,12 +229,12 @@ BOOL LLDataPackerBinaryBuffer::unpackBinaryData(U8 *value, S32 &size, const char
{
BOOL success = TRUE;
success &= verifyLength(4, name);
htonmemcpy(&size, mCurBufferp, MVT_S32, 4);
htolememcpy(&size, mCurBufferp, MVT_S32, 4);
mCurBufferp += 4;
success &= verifyLength(size, name);
if (success)
{
htonmemcpy(value, mCurBufferp, MVT_VARIABLE, size);
htolememcpy(value, mCurBufferp, MVT_VARIABLE, size);
mCurBufferp += size;
}
else
......@@ -253,7 +253,7 @@ BOOL LLDataPackerBinaryBuffer::packBinaryDataFixed(const U8 *value, S32 size, co
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value, MVT_VARIABLE, size);
htolememcpy(mCurBufferp, value, MVT_VARIABLE, size);
}
mCurBufferp += size;
return success;
......@@ -264,7 +264,7 @@ BOOL LLDataPackerBinaryBuffer::unpackBinaryDataFixed(U8 *value, S32 size, const
{
BOOL success = TRUE;
success &= verifyLength(size, name);
htonmemcpy(value, mCurBufferp, MVT_VARIABLE, size);
htolememcpy(value, mCurBufferp, MVT_VARIABLE, size);
mCurBufferp += size;
return success;
}
......@@ -302,7 +302,7 @@ BOOL LLDataPackerBinaryBuffer::packU16(const U16 value, const char *name)
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &value, MVT_U16, 2);
htolememcpy(mCurBufferp, &value, MVT_U16, 2);
}
mCurBufferp += 2;
return success;
......@@ -314,7 +314,7 @@ BOOL LLDataPackerBinaryBuffer::unpackU16(U16 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(sizeof(U16), name);
htonmemcpy(&value, mCurBufferp, MVT_U16, 2);
htolememcpy(&value, mCurBufferp, MVT_U16, 2);
mCurBufferp += 2;
return success;
}
......@@ -327,7 +327,7 @@ BOOL LLDataPackerBinaryBuffer::packU32(const U32 value, const char *name)
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &value, MVT_U32, 4);
htolememcpy(mCurBufferp, &value, MVT_U32, 4);
}
mCurBufferp += 4;
return success;
......@@ -339,7 +339,7 @@ BOOL LLDataPackerBinaryBuffer::unpackU32(U32 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(sizeof(U32), name);
htonmemcpy(&value, mCurBufferp, MVT_U32, 4);
htolememcpy(&value, mCurBufferp, MVT_U32, 4);
mCurBufferp += 4;
return success;
}
......@@ -352,7 +352,7 @@ BOOL LLDataPackerBinaryBuffer::packS32(const S32 value, const char *name)
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &value, MVT_S32, 4);
htolememcpy(mCurBufferp, &value, MVT_S32, 4);
}
mCurBufferp += 4;
return success;
......@@ -364,7 +364,7 @@ BOOL LLDataPackerBinaryBuffer::unpackS32(S32 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(sizeof(S32), name);
htonmemcpy(&value, mCurBufferp, MVT_S32, 4);
htolememcpy(&value, mCurBufferp, MVT_S32, 4);
mCurBufferp += 4;
return success;
}
......@@ -377,7 +377,7 @@ BOOL LLDataPackerBinaryBuffer::packF32(const F32 value, const char *name)
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &value, MVT_F32, 4);
htolememcpy(mCurBufferp, &value, MVT_F32, 4);
}
mCurBufferp += 4;
return success;
......@@ -389,7 +389,7 @@ BOOL LLDataPackerBinaryBuffer::unpackF32(F32 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(sizeof(F32), name);
htonmemcpy(&value, mCurBufferp, MVT_F32, 4);
htolememcpy(&value, mCurBufferp, MVT_F32, 4);
mCurBufferp += 4;
return success;
}
......@@ -402,7 +402,7 @@ BOOL LLDataPackerBinaryBuffer::packColor4(const LLColor4 &value, const char *nam
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.mV, MVT_LLVector4, 16);
htolememcpy(mCurBufferp, value.mV, MVT_LLVector4, 16);
}
mCurBufferp += 16;
return success;
......@@ -414,7 +414,7 @@ BOOL LLDataPackerBinaryBuffer::unpackColor4(LLColor4 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(16, name);
htonmemcpy(value.mV, mCurBufferp, MVT_LLVector4, 16);
htolememcpy(value.mV, mCurBufferp, MVT_LLVector4, 16);
mCurBufferp += 16;
return success;
}
......@@ -427,7 +427,7 @@ BOOL LLDataPackerBinaryBuffer::packColor4U(const LLColor4U &value, const char *n
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.mV, MVT_VARIABLE, 4);
htolememcpy(mCurBufferp, value.mV, MVT_VARIABLE, 4);
}
mCurBufferp += 4;
return success;
......@@ -439,7 +439,7 @@ BOOL LLDataPackerBinaryBuffer::unpackColor4U(LLColor4U &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(4, name);
htonmemcpy(value.mV, mCurBufferp, MVT_VARIABLE, 4);
htolememcpy(value.mV, mCurBufferp, MVT_VARIABLE, 4);
mCurBufferp += 4;
return success;
}
......@@ -453,8 +453,8 @@ BOOL LLDataPackerBinaryBuffer::packVector2(const LLVector2 &value, const char *n
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, &value.mV[0], MVT_F32, 4);
htonmemcpy(mCurBufferp+4, &value.mV[1], MVT_F32, 4);
htolememcpy(mCurBufferp, &value.mV[0], MVT_F32, 4);
htolememcpy(mCurBufferp+4, &value.mV[1], MVT_F32, 4);
}
mCurBufferp += 8;
return success;
......@@ -466,8 +466,8 @@ BOOL LLDataPackerBinaryBuffer::unpackVector2(LLVector2 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(8, name);
htonmemcpy(&value.mV[0], mCurBufferp, MVT_F32, 4);
htonmemcpy(&value.mV[1], mCurBufferp+4, MVT_F32, 4);
htolememcpy(&value.mV[0], mCurBufferp, MVT_F32, 4);
htolememcpy(&value.mV[1], mCurBufferp+4, MVT_F32, 4);
mCurBufferp += 8;
return success;
}
......@@ -480,7 +480,7 @@ BOOL LLDataPackerBinaryBuffer::packVector3(const LLVector3 &value, const char *n
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.mV, MVT_LLVector3, 12);
htolememcpy(mCurBufferp, value.mV, MVT_LLVector3, 12);
}
mCurBufferp += 12;
return success;
......@@ -492,7 +492,7 @@ BOOL LLDataPackerBinaryBuffer::unpackVector3(LLVector3 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(12, name);
htonmemcpy(value.mV, mCurBufferp, MVT_LLVector3, 12);
htolememcpy(value.mV, mCurBufferp, MVT_LLVector3, 12);
mCurBufferp += 12;
return success;
}
......@@ -504,7 +504,7 @@ BOOL LLDataPackerBinaryBuffer::packVector4(const LLVector4 &value, const char *n
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.mV, MVT_LLVector4, 16);
htolememcpy(mCurBufferp, value.mV, MVT_LLVector4, 16);
}
mCurBufferp += 16;
return success;
......@@ -516,7 +516,7 @@ BOOL LLDataPackerBinaryBuffer::unpackVector4(LLVector4 &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(16, name);
htonmemcpy(value.mV, mCurBufferp, MVT_LLVector4, 16);
htolememcpy(value.mV, mCurBufferp, MVT_LLVector4, 16);
mCurBufferp += 16;
return success;
}
......@@ -528,7 +528,7 @@ BOOL LLDataPackerBinaryBuffer::packUUID(const LLUUID &value, const char *name)
if (mWriteEnabled)
{
htonmemcpy(mCurBufferp, value.mData, MVT_LLUUID, 16);
htolememcpy(mCurBufferp, value.mData, MVT_LLUUID, 16);
}
mCurBufferp += 16;
return success;
......@@ -540,7 +540,7 @@ BOOL LLDataPackerBinaryBuffer::unpackUUID(LLUUID &value, const char *name)
BOOL success = TRUE;
success &= verifyLength(16, name);
htonmemcpy(value.mData, mCurBufferp, MVT_LLUUID, 16);
htolememcpy(value.mData, mCurBufferp, MVT_LLUUID, 16);
mCurBufferp += 16;
return success;
}
......
......@@ -373,7 +373,7 @@ std::string LLMail::encryptIMEmailAddress(const LLUUID& from_agent_id,
// Convert input data into a binary blob
std::vector<U8> data;
data.resize(data_size);
// *NOTE: This may suffer from endian issues. Could be htonmemcpy.
// *NOTE: This may suffer from endian issues. Could be htolememcpy.
memcpy(&data[0], &time, 4);
memcpy(&data[4], &from_agent_id.mData[0], UUID_BYTES);
memcpy(&data[4 + UUID_BYTES], &to_agent_id.mData[0], UUID_BYTES);
......
......@@ -47,7 +47,7 @@ void LLMsgVarData::addData(const void *data, S32 size, EMsgVariableType type, S3
{
delete[] mData; // Delete it if it already exists
mData = new U8[size];
htonmemcpy(mData, data, mType, size);
htolememcpy(mData, data, mType, size);
}
}
......
......@@ -689,14 +689,14 @@ static S32 buildBlock(U8* buffer, S32 buffer_size, const LLMessageBlock* templat
{
case 1:
sizeb = size;
htonmemcpy(&buffer[result], &sizeb, MVT_U8, 1);
htolememcpy(&buffer[result], &sizeb, MVT_U8, 1);
break;
case 2:
sizeh = size;
htonmemcpy(&buffer[result], &sizeh, MVT_U16, 2);
htolememcpy(&buffer[result], &sizeh, MVT_U16, 2);
break;
case 4:
htonmemcpy(&buffer[result], &size, MVT_S32, 4);
htolememcpy(&buffer[result], &size, MVT_S32, 4);
break;
default:
LL_ERRS() << "Attempting to build variable field with unknown size of " << size << LL_ENDL;
......
......@@ -645,15 +645,15 @@ BOOL LLTemplateMessageReader::decodeData(const U8* buffer, const LLHost& sender
switch(data_size)
{
case 1:
htonmemcpy(&tsizeb, &buffer[decode_pos], MVT_U8, 1);
htolememcpy(&tsizeb, &buffer[decode_pos], MVT_U8, 1);
tsize = tsizeb;
break;
case 2:
htonmemcpy(&tsizeh, &buffer[decode_pos], MVT_U16, 2);
htolememcpy(&tsizeh, &buffer[decode_pos], MVT_U16, 2);
tsize = tsizeh;
break;
case 4:
htonmemcpy(&tsize, &buffer[decode_pos], MVT_U32, 4);
htolememcpy(&tsize, &buffer[decode_pos], MVT_U32, 4);
break;
default:
LL_ERRS() << "Attempting to read variable field with unknown size of " << data_size << LL_ENDL;
......
......@@ -245,7 +245,7 @@ void LLXfer::sendPacket(S32 packet_num)
num_copy);
}
fdata_size += sizeof(S32);
htonmemcpy(fdata_buf,&mXferSize, MVT_S32, sizeof(S32));
htolememcpy(fdata_buf,&mXferSize, MVT_S32, sizeof(S32));
}
S32 encoded_packetnum = encodePacketNum(packet_num,last_packet);
......
......@@ -860,10 +860,10 @@ void null_message_callback(LLMessageSystem *msg, void **data);
//
#if !defined( LL_BIG_ENDIAN ) && !defined( LL_LITTLE_ENDIAN )
#error Unknown endianness for htonmemcpy. Did you miss a common include?
#error Unknown endianness for htolememcpy. Did you miss a common include?
#endif
static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type, size_t n)
static inline void *htolememcpy(void *vs, const void *vct, EMsgVariableType type, size_t n)
{
char *s = (char *)vs;
const char *ct = (const char *)vct;
......@@ -886,7 +886,7 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_S16:
if (n != 2)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
*(s + 1) = *(ct);
......@@ -901,7 +901,7 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_F32:
if (n != 4)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
*(s + 3) = *(ct);
......@@ -918,7 +918,7 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_F64:
if (n != 8)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
*(s + 7) = *(ct);
......@@ -938,12 +938,12 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_LLQuaternion: // We only send x, y, z and infer w (we set x, y, z to ensure that w >= 0)
if (n != 12)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
htonmemcpy(s + 8, ct + 8, MVT_F32, 4);
htonmemcpy(s + 4, ct + 4, MVT_F32, 4);
return(htonmemcpy(s, ct, MVT_F32, 4));
htolememcpy(s + 8, ct + 8, MVT_F32, 4);
htolememcpy(s + 4, ct + 4, MVT_F32, 4);
return(htolememcpy(s, ct, MVT_F32, 4));
#else
return(memcpy(s,ct,n)); /* Flawfinder: ignore */
#endif
......@@ -951,12 +951,12 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_LLVector3d:
if (n != 24)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
htonmemcpy(s + 16, ct + 16, MVT_F64, 8);
htonmemcpy(s + 8, ct + 8, MVT_F64, 8);
return(htonmemcpy(s, ct, MVT_F64, 8));
htolememcpy(s + 16, ct + 16, MVT_F64, 8);
htolememcpy(s + 8, ct + 8, MVT_F64, 8);
return(htolememcpy(s, ct, MVT_F64, 8));
#else
return(memcpy(s,ct,n)); /* Flawfinder: ignore */
#endif
......@@ -964,13 +964,13 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_LLVector4:
if (n != 16)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
htonmemcpy(s + 12, ct + 12, MVT_F32, 4);
htonmemcpy(s + 8, ct + 8, MVT_F32, 4);
htonmemcpy(s + 4, ct + 4, MVT_F32, 4);
return(htonmemcpy(s, ct, MVT_F32, 4));
htolememcpy(s + 12, ct + 12, MVT_F32, 4);
htolememcpy(s + 8, ct + 8, MVT_F32, 4);
htolememcpy(s + 4, ct + 4, MVT_F32, 4);
return(htolememcpy(s, ct, MVT_F32, 4));
#else
return(memcpy(s,ct,n)); /* Flawfinder: ignore */
#endif
......@@ -978,12 +978,12 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_U16Vec3:
if (n != 6)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
htonmemcpy(s + 4, ct + 4, MVT_U16, 2);
htonmemcpy(s + 2, ct + 2, MVT_U16, 2);
return(htonmemcpy(s, ct, MVT_U16, 2));
htolememcpy(s + 4, ct + 4, MVT_U16, 2);
htolememcpy(s + 2, ct + 2, MVT_U16, 2);
return(htolememcpy(s, ct, MVT_U16, 2));
#else
return(memcpy(s,ct,n)); /* Flawfinder: ignore */
#endif
......@@ -991,13 +991,13 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_U16Quat:
if (n != 8)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
htonmemcpy(s + 6, ct + 6, MVT_U16, 2);
htonmemcpy(s + 4, ct + 4, MVT_U16, 2);
htonmemcpy(s + 2, ct + 2, MVT_U16, 2);
return(htonmemcpy(s, ct, MVT_U16, 2));
htolememcpy(s + 6, ct + 6, MVT_U16, 2);
htolememcpy(s + 4, ct + 4, MVT_U16, 2);
htolememcpy(s + 2, ct + 2, MVT_U16, 2);
return(htolememcpy(s, ct, MVT_U16, 2));
#else
return(memcpy(s,ct,n)); /* Flawfinder: ignore */
#endif
......@@ -1005,15 +1005,15 @@ static inline void *htonmemcpy(void *vs, const void *vct, EMsgVariableType type,
case MVT_S16Array:
if (n % 2)
{
LL_ERRS() << "Size argument passed to htonmemcpy doesn't match swizzle type size" << LL_ENDL;
LL_ERRS() << "Size argument passed to htolememcpy doesn't match swizzle type size" << LL_ENDL;
}
#ifdef LL_BIG_ENDIAN
length = n % 2;
for (i = 1; i < length; i++)
{