how the fuck didnt that work before!

SVN revision: 14731
This commit is contained in:
Carsten Haitzler 2005-05-12 14:45:15 +00:00
parent 5321d3758e
commit 8b120cbfc4
2 changed files with 7 additions and 3 deletions

View File

@ -35,6 +35,10 @@ extern "C" {
/** /**
* Macros used for generic data packing * Macros used for generic data packing
*/ */
EAPI unsigned short _ecore_ipc_swap_16(unsigned short v);
EAPI unsigned int _ecore_ipc_swap_32(unsigned int v);
EAPI unsigned long long _ecore_ipc_swap_64(unsigned long long v);
#ifdef WORDS_BIGENDIAN #ifdef WORDS_BIGENDIAN
#define ECORE_IPC_SWAP2NET64(x) _ecore_ipc_swap_64(x) #define ECORE_IPC_SWAP2NET64(x) _ecore_ipc_swap_64(x)
#define ECORE_IPC_SWAP2CPU64(x) _ecore_ipc_swap_64(x) #define ECORE_IPC_SWAP2CPU64(x) _ecore_ipc_swap_64(x)

View File

@ -29,7 +29,7 @@
#define DLT_R2 15 #define DLT_R2 15
/* byte swappers - for dealing with big vs little endian machines */ /* byte swappers - for dealing with big vs little endian machines */
static unsigned short unsigned short
_ecore_ipc_swap_16(unsigned short v) _ecore_ipc_swap_16(unsigned short v)
{ {
unsigned char *s, t; unsigned char *s, t;
@ -39,7 +39,7 @@ _ecore_ipc_swap_16(unsigned short v)
return v; return v;
} }
static unsigned int unsigned int
_ecore_ipc_swap_32(unsigned int v) _ecore_ipc_swap_32(unsigned int v)
{ {
unsigned char *s, t; unsigned char *s, t;
@ -50,7 +50,7 @@ _ecore_ipc_swap_32(unsigned int v)
return v; return v;
} }
static unsigned long long unsigned long long
_ecore_ipc_swap_64(unsigned long long v) _ecore_ipc_swap_64(unsigned long long v)
{ {
unsigned char *s, t; unsigned char *s, t;