Send message to a worker

This commit is contained in:
2024-03-30 17:14:49 -04:00
parent 3f8bd314b6
commit e4d2076fa2

View File

@@ -166,17 +166,22 @@ int main(int argc, char **argv) {
break;
}
// reply addr
zmsg_pop(msg);
// reply id
char *id = zmsg_popstr(msg);
// null frame
zmsg_pop(msg);
struct guestfs_inpsect_command *c = guestfs_inspect_zmsg_to_command(msg);
if (STREQ(name, c->name)) {
// send request to worker
printf("name equal\n");
zactor_send(worker, &msg);
} else {
printf("name not equal\n");
}
/* zmsg_t *reply = zmsg_recv(frontend); */
}
zactor_destroy(&worker);