Changeset 1029 for pjproject/trunk
- Timestamp:
- Mar 1, 2007 6:56:02 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib/src/pjlib-test/sock.c
r974 r1029 52 52 * - pj_sock_listen() 53 53 * - pj_sock_accept() 54 * - pj_gethostbyname() 54 55 * 55 56 * … … 442 443 } 443 444 445 static int gethostbyname_test(void) 446 { 447 pj_str_t host; 448 pj_hostent he; 449 pj_status_t status; 450 451 /* Testing pj_gethostbyname() with invalid host */ 452 host = pj_str("an-invalid-host-name"); 453 status = pj_gethostbyname(&host, &he); 454 455 /* Must return failure! */ 456 if (status == PJ_SUCCESS) 457 return -20100; 458 else 459 return 0; 460 } 461 444 462 int sock_test() 445 463 { … … 449 467 450 468 rc = format_test(); 469 if (rc != 0) 470 return rc; 471 472 rc = gethostbyname_test(); 451 473 if (rc != 0) 452 474 return rc;
Note: See TracChangeset
for help on using the changeset viewer.