Selaa lähdekoodia

bugfix: unresolved host should return -1 instead of 0

ncannasse 6 vuotta sitten
vanhempi
commit
1d7469257d
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      src/std/socket.c

+ 1 - 1
src/std/socket.c

@@ -202,7 +202,7 @@ HL_PRIM int hl_host_resolve( vbyte *host ) {
 #	endif
 		if( h == NULL ) {
 			hl_blocking(false);
-			return 0;
+			return -1;
 		}
 		ip = *((unsigned int*)h->h_addr_list[0]);
 	}