Create prototype for IPC_CREATE macro on linux,
and change return type to pointer.
This commit is contained in:
		| @@ -34,7 +34,8 @@ int firstReadAfterWrite = 0; | |||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #ifdef SSCS_LINUX_PLAT_F | #ifdef SSCS_LINUX_PLAT_F | ||||||
| int ipc_unx_create() | void* ipc_unx_create() | ||||||
|  |  | ||||||
| { | { | ||||||
|     int retVal = 0; |     int retVal = 0; | ||||||
|     struct sockaddr_un servAddr; |     struct sockaddr_un servAddr; | ||||||
| @@ -63,7 +64,7 @@ int ipc_unx_create() | |||||||
|         else |         else | ||||||
|             retVal = sockFd; |             retVal = sockFd; | ||||||
|     }while(0); |     }while(0); | ||||||
|     return retVal; |     return (void*)retVal; | ||||||
| } | } | ||||||
|  |  | ||||||
| #else | #else | ||||||
|   | |||||||
| @@ -42,6 +42,11 @@ typedef uint8_t Byte; | |||||||
| #include <errno.h> | #include <errno.h> | ||||||
| #include <unistd.h> | #include <unistd.h> | ||||||
|  |  | ||||||
|  | void* ipc_unx_create(void); | ||||||
|  | int ipc_unx_write(int fd, Byte *pData, int bytes); | ||||||
|  | int ipc_unx_read(int fd, Byte *pData, int bytes); | ||||||
|  | int ipc_unx_close(int fd); | ||||||
|  |  | ||||||
| #define IPC_CREATE(...) ipc_unx_create(__VA_ARGS__); | #define IPC_CREATE(...) ipc_unx_create(__VA_ARGS__); | ||||||
| #define IPC_READ(...)   ipc_unx_read(__VA_ARGS__); | #define IPC_READ(...)   ipc_unx_read(__VA_ARGS__); | ||||||
| #define IPC_WRITE(...)  ipc_unx_write(__VA_ARGS__); | #define IPC_WRITE(...)  ipc_unx_write(__VA_ARGS__); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user