--- libaitrpc/example/tsrv.c 2010/06/28 15:18:43 1.1.1.1.2.2 +++ libaitrpc/example/tsrv.c 2010/06/28 17:10:39 1.1.1.1.2.3 @@ -31,6 +31,8 @@ int main() { rpc_srv_t *srv; rpc_func_t *f; + pthread_t tid[2]; + int ret; srv = rpc_srv_initServer(100, 2, 1, 2, "0.0.0.0", 11111); if (!srv) { @@ -56,10 +58,8 @@ int main() if (!fork()) { setsid(); - if (rpc_srv_execServer(srv) == -1) { - printf("error:: errno=%d %s\n", rpc_GetErrno(), rpc_GetError()); - return 2; - } + pthread_create(&tid[1], NULL, rpc_srv_execBLOBServer, srv); + rpc_srv_execServer(srv); } rpc_srv_endBLOBServer(srv);