summaryrefslogtreecommitdiff
path: root/legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2010-09-30 07:35:00 +0000
committerVincent Torri <vincent.torri@gmail.com>2010-09-30 07:35:00 +0000
commit1c1f20484ecc1af9fe106486608fd5f37c2da730 (patch)
treee8bfdb5fe4cc13c5ad181fe3d12f41a6584e84df /legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h
parent33ecb571b63ada56f6523d3bac3a96a5aa13853b (diff)
tab--
SVN revision: 52922
Diffstat (limited to '')
-rw-r--r--legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h48
1 files changed, 24 insertions, 24 deletions
diff --git a/legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h b/legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h
index 8011539f95..000fca9150 100644
--- a/legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h
+++ b/legacy/ecore/src/lib/ecore_ipc/Ecore_Ipc.h
@@ -68,44 +68,44 @@ EAPI unsigned long long _ecore_ipc_swap_64(unsigned long long v);
68/* unpacking */ 68/* unpacking */
69#define ECORE_IPC_GET64(v)\ 69#define ECORE_IPC_GET64(v)\
70 { \ 70 { \
71 p->v = ECORE_IPC_SWAP2CPU64(*(long long *)(ptr)); \ 71 p->v = ECORE_IPC_SWAP2CPU64(*(long long *)(ptr)); \
72 ptr += 8; \ 72 ptr += 8; \
73 } 73 }
74#define ECORE_IPC_GET32(v)\ 74#define ECORE_IPC_GET32(v)\
75 { \ 75 { \
76 p->v = ECORE_IPC_SWAP2CPU32(*(int *)(ptr)); \ 76 p->v = ECORE_IPC_SWAP2CPU32(*(int *)(ptr)); \
77 ptr += 4; \ 77 ptr += 4; \
78 } 78 }
79#define ECORE_IPC_GET16(v)\ 79#define ECORE_IPC_GET16(v)\
80 { \ 80 { \
81 p->v = ECORE_IPC_SWAP2CPU16(*(short *)(ptr)); \ 81 p->v = ECORE_IPC_SWAP2CPU16(*(short *)(ptr)); \
82 ptr += 2; \ 82 ptr += 2; \
83 } 83 }
84#define ECORE_IPC_GET8(v) \ 84#define ECORE_IPC_GET8(v) \
85 { \ 85 { \
86 p->v = ECORE_IPC_SWAP2CPU8(*(char *)(ptr)); \ 86 p->v = ECORE_IPC_SWAP2CPU8(*(char *)(ptr)); \
87 ptr += 1; \ 87 ptr += 1; \
88 } 88 }
89/* packing */ 89/* packing */
90#define ECORE_IPC_PUT64(v)\ 90#define ECORE_IPC_PUT64(v)\
91 { \ 91 { \
92 *(long long *)(ptr) = ECORE_IPC_SWAP2NET64(p->v); \ 92 *(long long *)(ptr) = ECORE_IPC_SWAP2NET64(p->v); \
93 ptr += 8; \ 93 ptr += 8; \
94 } 94 }
95#define ECORE_IPC_PUT32(v)\ 95#define ECORE_IPC_PUT32(v)\
96 { \ 96 { \
97 *(int *)(ptr) = ECORE_IPC_SWAP2NET32(p->v); \ 97 *(int *)(ptr) = ECORE_IPC_SWAP2NET32(p->v); \
98 ptr += 4; \ 98 ptr += 4; \
99 } 99 }
100#define ECORE_IPC_PUT16(v)\ 100#define ECORE_IPC_PUT16(v)\
101 { \ 101 { \
102 *(short *)(ptr) = ECORE_IPC_SWAP2NET16(p->v); \ 102 *(short *)(ptr) = ECORE_IPC_SWAP2NET16(p->v); \
103 ptr += 2; \ 103 ptr += 2; \
104 } 104 }
105#define ECORE_IPC_PUT8(v) \ 105#define ECORE_IPC_PUT8(v) \
106 { \ 106 { \
107 *(char *)(ptr) = ECORE_IPC_SWAP2NET8(p->v); \ 107 *(char *)(ptr) = ECORE_IPC_SWAP2NET8(p->v); \
108 ptr += 1; \ 108 ptr += 1; \
109 } 109 }
110/* padding data */ 110/* padding data */
111#define ECORE_IPC_PAD8() ptr += 1 111#define ECORE_IPC_PAD8() ptr += 1
@@ -123,16 +123,16 @@ EAPI unsigned long long _ecore_ipc_swap_64(unsigned long long v);
123#define ECORE_IPC_CHEKS() if (*((unsigned char *)d + s - 1) != 0) return 0; 123#define ECORE_IPC_CHEKS() if (*((unsigned char *)d + s - 1) != 0) return 0;
124#define ECORE_IPC_GETS(v) \ 124#define ECORE_IPC_GETS(v) \
125 { \ 125 { \
126 if (ptr < ((unsigned char *)d + s)) \ 126 if (ptr < ((unsigned char *)d + s)) \
127 { \ 127 { \
128 p->v = (char *)ptr; \ 128 p->v = (char *)ptr; \
129 ptr += strlen(p->v) + 1; \ 129 ptr += strlen(p->v) + 1; \
130 } \ 130 } \
131 } 131 }
132#define ECORE_IPC_PUTS(v, l)\ 132#define ECORE_IPC_PUTS(v, l)\
133 { \ 133 { \
134 strcpy((char *)ptr, p->v); \ 134 strcpy((char *)ptr, p->v); \
135 ptr += l + 1; \ 135 ptr += l + 1; \
136 } 136 }
137 137
138/* handy to calculate what sized block we need to alloc */ 138/* handy to calculate what sized block we need to alloc */
@@ -189,7 +189,7 @@ EAPI unsigned long long _ecore_ipc_swap_64(unsigned long long v);
189 p = malloc(sizeof(typ)); 189 p = malloc(sizeof(typ));
190 190
191#define ECORE_IPC_DEC_EINA_LIST_FOOT() \ 191#define ECORE_IPC_DEC_EINA_LIST_FOOT() \
192 l = eina_list_append(l, p); \ 192 l = eina_list_append(l, p); \
193 } \ 193 } \
194 return l 194 return l
195#define ECORE_IPC_ENC_EINA_LIST_HEAD_START(typ) \ 195#define ECORE_IPC_ENC_EINA_LIST_HEAD_START(typ) \