*
* Note that *remaining is altered on both success and failure. */
- size_t n = 0, j, tn = SIZE_MAX, m = 0, entry_size = 0;
+ size_t n = 0, j, tn = SIZE_MAX, entry_size = 0;
char *identifier = NULL, *message = NULL;
struct iovec *iovec = NULL;
int priority = LOG_INFO;
}
/* n existing properties, 1 new, +1 for _TRANSPORT */
- if (!GREEDY_REALLOC(iovec, m,
+ if (!GREEDY_REALLOC(iovec,
n + 2 +
N_IOVEC_META_FIELDS + N_IOVEC_OBJECT_FIELDS +
client_context_extra_fields_n_iovec(context))) {
server_forward_wall(s, priority, identifier, message, ucred);
}
- server_dispatch_message(s, iovec, n, m, context, tv, priority, object_pid);
+ server_dispatch_message(s, iovec, n, MALLOC_ELEMENTSOF(iovec), context, tv, priority, object_pid);
finish:
for (j = 0; j < n; j++) {