Skip to content
Snippets Groups Projects
Commit d5fa4289 authored by Tilghman Lesher's avatar Tilghman Lesher
Browse files

Fixes for gcc 4.4

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@227824 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent b3bd4336
No related branches found
No related tags found
No related merge requests found
......@@ -50,9 +50,16 @@ static inline unsigned short get_unaligned_uint16(const void *p)
static inline void put_unaligned_uint64(void *p, uint64_t datum)
{
struct { uint64_t d; } __attribute__((packed)) *pp = p;
unsigned char *cp = p;
pp->d = datum;
cp[0] = (datum >> 56) & 0xff;
cp[1] = (datum >> 48) & 0xff;
cp[2] = (datum >> 40) & 0xff;
cp[3] = (datum >> 32) & 0xff;
cp[4] = (datum >> 24) & 0xff;
cp[5] = (datum >> 16) & 0xff;
cp[6] = (datum >> 8) & 0xff;
cp[7] = (datum >> 0) & 0xff;
}
static inline void put_unaligned_uint32(void *p, unsigned int datum)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment