diff --git a/posix/Socket.c b/posix/Socket.c index a3f4434..d19680b 100644 --- a/posix/Socket.c +++ b/posix/Socket.c @@ -91,7 +91,6 @@ CgeNetSocket *CgeNetOpen(int domain, int type, int *result) { int code = CGE_NET_ENOMEM; if ((socket = malloc(sizeof(*socket)))) { - code = CGE_NET_EOK; if ((code = socketInit(socket, domain, type))) { free(socket); socket = NULL; diff --git a/win32/Socket.c b/win32/Socket.c index a7e3b62..825a0fd 100644 --- a/win32/Socket.c +++ b/win32/Socket.c @@ -90,7 +90,6 @@ CgeNetSocket *CgeNetOpen(int domain, int type, int *result) { int code = CGE_NET_ENOMEM; if ((socket = malloc(sizeof(*socket)))) { - code = CGE_NET_EOK; if ((code = socketInit(socket, domain, type))) { free(socket); socket = NULL;