strncpy(z_buf, string, sizeof(z_buf));
z_buf[sizeof(z_buf)-1] = '\0';
strncpy(z_buf, string, sizeof(z_buf));
z_buf[sizeof(z_buf)-1] = '\0';
- printf(" %s", tok2str(z_types, "type %d", z.kind));
+ ND_PRINT((ndo, " %s", tok2str(z_types, "type %d", z.kind)));
PARSE_FIELD_STR(ackdata);
if (!lose && strcmp(ackdata, "SENT"))
PARSE_FIELD_STR(ackdata);
if (!lose && strcmp(ackdata, "SENT"))
if (!strcmp(z.class, "USER_LOCATE")) {
if (!strcmp(z.opcode, "USER_HIDE"))
if (!strcmp(z.class, "USER_LOCATE")) {
if (!strcmp(z.opcode, "USER_HIDE"))
!strcmp(z.opcode, "SUBSCRIBE_NODEFS") ||
!strcmp(z.opcode, "UNSUBSCRIBE")) {
!strcmp(z.opcode, "SUBSCRIBE_NODEFS") ||
!strcmp(z.opcode, "UNSUBSCRIBE")) {
- printf(" %ssub%s", strcmp(z.opcode, "SUBSCRIBE") ? "un" : "",
+ ND_PRINT((ndo, " %ssub%s", strcmp(z.opcode, "SUBSCRIBE") ? "un" : "",
- if (!lose) printf(" %s", z_triple(c, i, r));
+ if (!lose) ND_PRINT((ndo, " %s", z_triple(c, i, r)));
return;
}
if (!strcmp(z.inst, "REALM")) {
if (!strcmp(z.opcode, "ADD_SUBSCRIBE"))
return;
}
if (!strcmp(z.inst, "REALM")) {
if (!strcmp(z.opcode, "ADD_SUBSCRIBE"))
- printf(" hm_ctl %s", str_to_lower(z.inst));
- printf(" %s", str_to_lower(z.opcode));
+ ND_PRINT((ndo, " hm_ctl %s", str_to_lower(z.inst)));
+ ND_PRINT((ndo, " %s", str_to_lower(z.opcode)));
return;
}
if (!strcmp(z.class, "HM_STAT")) {
if (!strcmp(z.inst, "HMST_CLIENT") && !strcmp(z.opcode, "GIMMESTATS")) {
return;
}
if (!strcmp(z.class, "HM_STAT")) {
if (!strcmp(z.inst, "HMST_CLIENT") && !strcmp(z.opcode, "GIMMESTATS")) {
- printf(" wg_ctl %s", str_to_lower(z.inst));
- printf(" %s", str_to_lower(z.opcode));
+ ND_PRINT((ndo, " wg_ctl %s", str_to_lower(z.inst)));
+ ND_PRINT((ndo, " %s", str_to_lower(z.opcode)));
return;
}
if (!strcmp(z.class, "LOGIN")) {
if (!strcmp(z.opcode, "USER_FLUSH")) {
return;
}
if (!strcmp(z.class, "LOGIN")) {
if (!strcmp(z.opcode, "USER_FLUSH")) {
!strcmp(z.opcode, "REALM-ANNOUNCED") ||
!strcmp(z.opcode, "NET-VISIBLE") ||
!strcmp(z.opcode, "NET-ANNOUNCED")) {
!strcmp(z.opcode, "REALM-ANNOUNCED") ||
!strcmp(z.opcode, "NET-VISIBLE") ||
!strcmp(z.opcode, "NET-ANNOUNCED")) {
- printf(" to %s", z_triple(z.class, z.inst, z.recipient));
+ ND_PRINT((ndo, " to %s", z_triple(z.class, z.inst, z.recipient)));