diff options
author | 2019-08-11 15:52:46 +0000 | |
---|---|---|
committer | 2019-08-11 15:52:46 +0000 | |
commit | 903c564c4c2f4cf672613b34a580863ef1d8db4f (patch) | |
tree | ae8e0d06349b9c1ba37d99b9996eb576c41100e9 /usr.bin/snmp | |
parent | sync (diff) | |
download | wireguard-openbsd-903c564c4c2f4cf672613b34a580863ef1d8db4f.tar.xz wireguard-openbsd-903c564c4c2f4cf672613b34a580863ef1d8db4f.zip |
whitespace issues like a knife in my eyes
Diffstat (limited to 'usr.bin/snmp')
-rw-r--r-- | usr.bin/snmp/smi.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/usr.bin/snmp/smi.c b/usr.bin/snmp/smi.c index 28cb674c38b..637eb36af2f 100644 --- a/usr.bin/snmp/smi.c +++ b/usr.bin/snmp/smi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smi.c,v 1.2 2019/08/11 14:41:20 deraadt Exp $ */ +/* $OpenBSD: smi.c,v 1.3 2019/08/11 15:52:46 deraadt Exp $ */ /* * Copyright (c) 2019 Martijn van Duren <martijn@openbsd.org> @@ -181,7 +181,8 @@ smi_debug_elements(struct ber_element *root) fprintf(stderr, "(%u) encoding %u ", root->be_type, root->be_encoding); - if ((value = smi_print_element(root, 1, smi_os_default, smi_oidl_numeric)) == NULL) + if ((value = smi_print_element(root, 1, smi_os_default, + smi_oidl_numeric)) == NULL) goto invalid; switch (root->be_encoding) { @@ -256,8 +257,7 @@ smi_print_element(struct ber_element *root, int print_hint, if (asprintf(&str, "INTEGER: %s(%d)", d ? "true" : "false", d) == -1) goto fail; - } - else + } else if (asprintf(&str, "%s", d ? "true" : "false") == -1) goto fail; break; @@ -329,8 +329,7 @@ smi_print_element(struct ber_element *root, int print_hint, else if (root->be_type == SNMP_T_COUNTER64) hint = "Counter64: "; } - if (asprintf(&str, "%s%lld", print_hint ? hint : "", v) - == -1) + if (asprintf(&str, "%s%lld", print_hint ? hint : "", v) == -1) goto fail; break; case BER_TYPE_BITSTRING: |