VarlinkReply reply_callback;
JsonVariant *current;
+ VarlinkReplyFlags current_reply_flags;
VarlinkSymbol *current_method;
int peer_pidfd;
/* Clears the currently processed incoming message */
v->current = json_variant_unref(v->current);
v->current_method = NULL;
+ v->current_reply_flags = 0;
close_many(v->input_fds, v->n_input_fds);
v->input_fds = mfree(v->input_fds);
if (r < 0)
goto invalid;
+ v->current_reply_flags = flags;
+
if (IN_SET(v->state, VARLINK_AWAITING_REPLY, VARLINK_AWAITING_REPLY_MORE)) {
varlink_set_state(v, VARLINK_PROCESSING_REPLY);
varlink_clear_current(v);
if (v->state == VARLINK_PROCESSING_REPLY) {
-
assert(v->n_pending > 0);
if (!FLAGS_SET(flags, VARLINK_REPLY_CONTINUES))
v->timestamp = now(CLOCK_MONOTONIC);
while (v->state == VARLINK_CALLING) {
-
r = varlink_process(v);
if (r < 0)
return r;
if (ret_error_id)
*ret_error_id = e ? json_variant_string(e) : NULL;
if (ret_flags)
- *ret_flags = 0;
+ *ret_flags = v->current_reply_flags;
return 1;
}