Lines Matching refs:conn

33 struct conn {  struct
263 static struct conn *conn; in vm_agentx_configure() local
278 if (conn != NULL) { in vm_agentx_configure()
279 agentx_free(conn->agentx); in vm_agentx_configure()
280 conn = NULL; in vm_agentx_configure()
288 if (strcmp(curpath, vmd_agentx->ax_path) != 0 || conn == NULL) { in vm_agentx_configure()
289 if (conn != NULL) { in vm_agentx_configure()
290 agentx_free(conn->agentx); in vm_agentx_configure()
291 conn = NULL; in vm_agentx_configure()
297 if ((conn = malloc(sizeof(*conn))) == NULL) in vm_agentx_configure()
300 evtimer_set(&conn->ev, vm_agentx_tryconnect, conn); in vm_agentx_configure()
302 if (agentx(vm_agentx_nofd, conn) == NULL) in vm_agentx_configure()
304 sess = agentx_session(conn->agentx, NULL, 0, "vmd", 0); in vm_agentx_configure()
373 struct conn *conn = cookie; in vm_agentx_nofd() local
375 conn->agentx = agentx; in vm_agentx_nofd()
376 event_del(&conn->ev); in vm_agentx_nofd()
378 free(conn); in vm_agentx_nofd()
380 vm_agentx_tryconnect(-1, 0, conn); in vm_agentx_nofd()
388 struct conn *conn = cookie; in vm_agentx_tryconnect() local
401 agentx_connect(conn->agentx, fd); in vm_agentx_tryconnect()
403 event_set(&conn->ev, fd, EV_READ|EV_PERSIST, vm_agentx_read, conn); in vm_agentx_tryconnect()
404 event_add(&conn->ev, NULL); in vm_agentx_tryconnect()
408 evtimer_set(&conn->ev, vm_agentx_tryconnect, conn); in vm_agentx_tryconnect()
409 evtimer_add(&conn->ev, &timeout); in vm_agentx_tryconnect()
415 struct conn *conn = cookie; in vm_agentx_read() local
417 agentx_read(conn->agentx); in vm_agentx_read()