--- libaitio/src/sock.c 2013/08/27 19:24:37 1.2.2.4 +++ libaitio/src/sock.c 2013/08/27 19:25:59 1.2.2.5 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: sock.c,v 1.2.2.4 2013/08/27 19:24:37 misho Exp $ +* $Id: sock.c,v 1.2.2.5 2013/08/27 19:25:59 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -207,6 +207,7 @@ thrCliClean(void *arg) { sock_cli_t *cli = (sock_cli_t*) arg; + shutdown(cli->cli_fd, SHUT_RDWR); close(cli->cli_fd); AIT_FREE_VAL(&cli->cli_buf); e_free(cli); @@ -223,7 +224,7 @@ io_thrCliWrapper(void *arg) ret = cli->cli_func(cli); pthread_cleanup_pop(42); - pthread_exit(NULL); + pthread_exit(ret); } /*