send NameOwnerChanged for unique name assignment too
This commit is contained in:
parent
adc299c847
commit
3f88fe4701
1 changed files with 9 additions and 0 deletions
9
server.c
9
server.c
|
@ -416,6 +416,15 @@ int handle_hello(bus_t *s, int i, wire_message_t *msg, wire_context_t *ctx, wire
|
|||
TRYPTR(wire_set_string(reply_ctx, s->names[unique_name_index].name));
|
||||
} _reply_end()
|
||||
|
||||
_signal_begin("sss", "NameOwnerChanged") {
|
||||
/* Name with a new owner */
|
||||
TRYPTR(wire_set_string(&signal_reply_ctx, s->names[unique_name_index].name));
|
||||
/* Old owner or empty string if none */
|
||||
TRYPTR(wire_set_string(&signal_reply_ctx, ""));
|
||||
/* New owner or empty string if none */
|
||||
TRYPTR(wire_set_string(&signal_reply_ctx, ""));
|
||||
} _signal_end();
|
||||
|
||||
printf("assigned unique name '%s' to connection %d\n", s->names[unique_name_index].name, i);
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue