init_network - fix some codepaths

This commit is contained in:
twinaphex 2016-05-03 04:28:58 +02:00
parent fd2096f3dc
commit 35b7d0423f

View File

@ -246,13 +246,13 @@ bool network_init(void)
sys_net_initialize_network(); sys_net_initialize_network();
if (cellNetCtlInit() < 0) if (cellNetCtlInit() < 0)
goto error; return false;
for (;;) for (;;)
{ {
int state; int state;
if (cellNetCtlGetState(&state) < 0) if (cellNetCtlGetState(&state) < 0)
goto error; return false;
if (state == CELL_NET_CTL_STATE_IPObtained) if (state == CELL_NET_CTL_STATE_IPObtained)
break; break;
@ -282,7 +282,7 @@ bool network_init(void)
#elif defined(GEKKO) #elif defined(GEKKO)
char t[16]; char t[16];
if (if_config(t, NULL, NULL, TRUE) < 0) if (if_config(t, NULL, NULL, TRUE) < 0)
goto error; return false;
#else #else
signal(SIGPIPE, SIG_IGN); /* Do not like SIGPIPE killing our app. */ signal(SIGPIPE, SIG_IGN); /* Do not like SIGPIPE killing our app. */
#endif #endif