connect() return -3

I am using Nuvoton MCU. My codes are like this. connect func answer -3. Why ? I dont understand.

uint8_t spi_rb(void){

uint8_t uData = 0;

SPI_WRITE_TX(SPI0, 0x00);

/* Check busy state */
while (SPI_IS_BUSY(SPI0));

while (SPI_GET_RX_FIFO_EMPTY_FLAG(SPI0) == 1);
uData = SPI_READ_RX(SPI0);

return uData;

}

void spi_wb(uint8_t b){

//SPIReadWrite(b);
while (SPI_GET_TX_FIFO_EMPTY_FLAG(SPI0) == 0) ;
SPI_WRITE_TX(SPI0, b);
/* Check busy state */

}

wiz_NetInfo gWIZNETINFO2 = {
.mac = {0x00, 0x08, 0xdc, 0xab, 0xcd, 0xef},
.ip = {192, 168, 1, 18}, // IP address
.sn = {255, 255, 255, 0}, // Subnet mask
.gw = {192, 168, 1, 1}, // Gateway address
.dns = {0,0,0,0},
.dhcp = NETINFO_STATIC};

socket(s,Sn_MR_TCP,5656,SF_TCP_NODELAY);
while(Baglan!=SOCK_OK){
Baglan=connect(s,serverIp,5656);
}
Baglan=0;