Merge "WebPMemToUint32: remove ptr cast to int"

This commit is contained in:
Pascal Massimino 2017-10-31 06:41:05 +00:00 committed by Gerrit Code Review
commit 3879074d99

View File

@ -66,7 +66,7 @@ WEBP_EXTERN void WebPSafeFree(void* const ptr);
// memcpy() is the safe way of moving potentially unaligned 32b memory.
static WEBP_INLINE uint32_t WebPMemToUint32(const uint8_t* const ptr) {
uint32_t A;
memcpy(&A, (const int*)ptr, sizeof(A));
memcpy(&A, ptr, sizeof(A));
return A;
}
static WEBP_INLINE void WebPUint32ToMem(uint8_t* const ptr, uint32_t val) {