diff options
author | ngie <ngie@FreeBSD.org> | 2016-12-31 10:32:49 +0000 |
---|---|---|
committer | ngie <ngie@FreeBSD.org> | 2016-12-31 10:32:49 +0000 |
commit | eada65d28aa46382291fb577f115698fabe04d18 (patch) | |
tree | b22d7786d88c3d7641b3a101016f6cefc6057e84 /contrib/bsnmp/lib | |
parent | f26e57240e91d732e0eb3083ce4e1048128caa53 (diff) | |
download | FreeBSD-src-eada65d28aa46382291fb577f115698fabe04d18.zip FreeBSD-src-eada65d28aa46382291fb577f115698fabe04d18.tar.gz |
MFC r310648:
style(9): clean up trailing whitespace
Diffstat (limited to 'contrib/bsnmp/lib')
-rw-r--r-- | contrib/bsnmp/lib/asn1.3 | 6 | ||||
-rw-r--r-- | contrib/bsnmp/lib/asn1.c | 8 | ||||
-rw-r--r-- | contrib/bsnmp/lib/asn1.h | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/bsnmpagent.3 | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/bsnmpclient.3 | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/bsnmplib.3 | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmp.c | 8 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmp.h | 6 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmpagent.c | 10 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmpagent.h | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmpclient.c | 12 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmpclient.h | 6 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmpcrypto.c | 2 | ||||
-rw-r--r-- | contrib/bsnmp/lib/snmppriv.h | 4 | ||||
-rw-r--r-- | contrib/bsnmp/lib/support.c | 8 | ||||
-rw-r--r-- | contrib/bsnmp/lib/support.h | 4 |
16 files changed, 47 insertions, 47 deletions
diff --git a/contrib/bsnmp/lib/asn1.3 b/contrib/bsnmp/lib/asn1.3 index 419a929..a9cf117 100644 --- a/contrib/bsnmp/lib/asn1.3 +++ b/contrib/bsnmp/lib/asn1.3 @@ -5,9 +5,9 @@ .\" Copyright (c) 2001-2003 .\" Fraunhofer Institute for Open Communication Systems (FhG Fokus). .\" All rights reserved. -.\" +.\" .\" Author: Harti Brandt <harti@FreeBSD.org> -.\" +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -16,7 +16,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" +.\" .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/asn1.c b/contrib/bsnmp/lib/asn1.c index 0c9d09a..03b5662 100644 --- a/contrib/bsnmp/lib/asn1.c +++ b/contrib/bsnmp/lib/asn1.c @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -285,7 +285,7 @@ asn_put_real_integer(struct asn_buf *b, u_char type, int64_t ival) enum asn_err ret; if (ival < 0) { - /* this may fail if |INT64_MIN| > |INT64_MAX| and + /* this may fail if |INT64_MIN| > |INT64_MAX| and * the value is between * INT64_MIN <= ival < -(INT64_MAX+1) */ val = (uint64_t)-(ival + 1); neg = 1; @@ -890,7 +890,7 @@ asn_slice_oid(struct asn_oid *dest, const struct asn_oid *src, memcpy(dest->subs, &src->subs[from], dest->len * sizeof(dest->subs[0])); } -/* +/* * Append from to to */ void diff --git a/contrib/bsnmp/lib/asn1.h b/contrib/bsnmp/lib/asn1.h index cf9a727..4aded8a 100644 --- a/contrib/bsnmp/lib/asn1.h +++ b/contrib/bsnmp/lib/asn1.h @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/bsnmpagent.3 b/contrib/bsnmp/lib/bsnmpagent.3 index 6b9c719..f9f2a7c 100644 --- a/contrib/bsnmp/lib/bsnmpagent.3 +++ b/contrib/bsnmp/lib/bsnmpagent.3 @@ -7,7 +7,7 @@ .\" All rights reserved. .\" .\" Author: Harti Brandt <harti@FreeBSD.org> -.\" +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -16,7 +16,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" +.\" .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/bsnmpclient.3 b/contrib/bsnmp/lib/bsnmpclient.3 index d4af60e..7a13a89 100644 --- a/contrib/bsnmp/lib/bsnmpclient.3 +++ b/contrib/bsnmp/lib/bsnmpclient.3 @@ -7,7 +7,7 @@ .\" All rights reserved. .\" .\" Author: Harti Brandt <harti@FreeBSD.org> -.\" +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -16,7 +16,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" +.\" .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/bsnmplib.3 b/contrib/bsnmp/lib/bsnmplib.3 index 12d676a..76b4bd4 100644 --- a/contrib/bsnmp/lib/bsnmplib.3 +++ b/contrib/bsnmp/lib/bsnmplib.3 @@ -13,7 +13,7 @@ .\" All rights reserved. .\" .\" Author: Harti Brandt <harti@FreeBSD.org> -.\" +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -22,7 +22,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" +.\" .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/snmp.c b/contrib/bsnmp/lib/snmp.c index 5354443..339853b 100644 --- a/contrib/bsnmp/lib/snmp.c +++ b/contrib/bsnmp/lib/snmp.c @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Copyright (c) 2010 The FreeBSD Foundation * All rights reserved. * @@ -19,7 +19,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -682,7 +682,7 @@ snmp_pdu_snoop(const struct asn_buf *b0) struct asn_buf b = *b0; /* <0x10|0x20> <len> <data...> */ - + if (b.asn_len == 0) return (0); if (b.asn_cptr[0] != (ASN_TYPE_SEQUENCE | ASN_TYPE_CONSTRUCTED)) { @@ -757,7 +757,7 @@ snmp_pdu_encode_header(struct asn_buf *b, struct snmp_pdu *pdu) if (asn_put_temp_header(b, (ASN_TYPE_SEQUENCE | ASN_TYPE_CONSTRUCTED), &v3_hdr_ptr) != ASN_ERR_OK) return (SNMP_CODE_FAILED); - + if (asn_put_integer(b, pdu->identifier) != ASN_ERR_OK) return (SNMP_CODE_FAILED); diff --git a/contrib/bsnmp/lib/snmp.h b/contrib/bsnmp/lib/snmp.h index 4657336..61e783e 100644 --- a/contrib/bsnmp/lib/snmp.h +++ b/contrib/bsnmp/lib/snmp.h @@ -4,14 +4,14 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Copyright (c) 2010 The FreeBSD Foundation * All rights reserved. * * Portions of this software were developed by Shteryana Sotirova Shopova * under sponsorship from the FreeBSD Foundation. * - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -20,7 +20,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/snmpagent.c b/contrib/bsnmp/lib/snmpagent.c index a425c37..8393aec 100644 --- a/contrib/bsnmp/lib/snmpagent.c +++ b/contrib/bsnmp/lib/snmpagent.c @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -515,7 +515,7 @@ snmp_getbulk(struct snmp_pdu *pdu, struct asn_buf *resp_b, /* PDU is full */ goto done; - if (cnt == 0) + if (cnt == 0) result = do_getnext(&context, &pdu->bindings[i], &resp->bindings[resp->nbindings], pdu); else @@ -689,7 +689,7 @@ snmp_set(struct snmp_pdu *pdu, struct asn_buf *resp_b, if (snmp_pdu_encode_header(resp_b, resp)) return (SNMP_RET_IGN); - /* + /* * 1. Find all nodes, check that they are writeable and * that the syntax is ok, copy over the binding to the response. */ @@ -967,7 +967,7 @@ snmp_dep_lookup(struct snmp_context *ctx, const struct asn_oid *obj, /* * Make an error response from a PDU. We do this without decoding the * variable bindings. This means we can sent the junk back to a caller - * that has sent us junk in the first place. + * that has sent us junk in the first place. */ enum snmp_ret snmp_make_errresp(const struct snmp_pdu *pdu, struct asn_buf *pdu_b, diff --git a/contrib/bsnmp/lib/snmpagent.h b/contrib/bsnmp/lib/snmpagent.h index 66019c9..204b517 100644 --- a/contrib/bsnmp/lib/snmpagent.h +++ b/contrib/bsnmp/lib/snmpagent.h @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/snmpclient.c b/contrib/bsnmp/lib/snmpclient.c index 95d3b68..03e5cbf 100644 --- a/contrib/bsnmp/lib/snmpclient.c +++ b/contrib/bsnmp/lib/snmpclient.c @@ -68,7 +68,7 @@ struct snmp_client snmp_client; /* List of all outstanding requests */ -struct sent_pdu { +struct sent_pdu { int reqid; struct snmp_pdu *pdu; struct timeval time; @@ -510,7 +510,7 @@ table_check_response(struct tabwork *work, const struct snmp_pdu *resp) table_free(work, 1); return (-2); } - + continue; } if (!asn_is_suboid(&work->descr->table, &b->var) || @@ -754,7 +754,7 @@ snmp_oid_append(struct asn_oid *oid, const char *fmt, ...) ret = 0; while (*fmt != '\0') { switch (*fmt++) { - case 'i': + case 'i': /* just an integer more */ if (oid->len + 1 > ASN_MAXOIDLEN) { warnx("%s: OID too long for integer", __func__); @@ -804,7 +804,7 @@ snmp_oid_append(struct asn_oid *oid, const char *fmt, ...) break; case 'b': - /* append `size` characters */ + /* append `size` characters */ str = (const u_char *)va_arg(va, const char *); if (oid->len + size > ASN_MAXOIDLEN) { warnx("%s: OID too long for string", __func__); @@ -852,7 +852,7 @@ snmp_client_init(struct snmp_client *c) strcpy(c->read_community, "public"); strcpy(c->write_community, "private"); - + c->security_model = SNMP_SECMODEL_USM; strcpy(c->cname, ""); @@ -863,7 +863,7 @@ snmp_client_init(struct snmp_client *c) c->txbuflen = c->rxbuflen = 10000; c->fd = -1; - + c->max_reqid = INT32_MAX; c->min_reqid = 0; c->next_reqid = 0; diff --git a/contrib/bsnmp/lib/snmpclient.h b/contrib/bsnmp/lib/snmpclient.h index 619f726..e7454b1 100644 --- a/contrib/bsnmp/lib/snmpclient.h +++ b/contrib/bsnmp/lib/snmpclient.h @@ -5,7 +5,7 @@ * * Author: Harti Brandt <harti@freebsd.org> * Kendy Kutzner - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -14,7 +14,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -59,7 +59,7 @@ typedef void (*snmp_send_cb_f)(struct snmp_pdu *, struct snmp_pdu *, void *); typedef void (*snmp_timeout_cb_f)(void * ); /* timeout start function */ -typedef void *(*snmp_timeout_start_f)(struct timeval *timeout, +typedef void *(*snmp_timeout_start_f)(struct timeval *timeout, snmp_timeout_cb_f callback, void *); /* timeout stop function */ diff --git a/contrib/bsnmp/lib/snmpcrypto.c b/contrib/bsnmp/lib/snmpcrypto.c index 05860d6..82c8660 100644 --- a/contrib/bsnmp/lib/snmpcrypto.c +++ b/contrib/bsnmp/lib/snmpcrypto.c @@ -322,7 +322,7 @@ snmp_calc_keychange(struct snmp_user *user, uint8_t *keychange) for (i = 0; i < keylen / 4; i++) rvalue[i] = random(); - + memcpy(keychange, user->auth_key, keylen); memcpy(keychange + keylen, rvalue, keylen); diff --git a/contrib/bsnmp/lib/snmppriv.h b/contrib/bsnmp/lib/snmppriv.h index c0e4479..5b66992 100644 --- a/contrib/bsnmp/lib/snmppriv.h +++ b/contrib/bsnmp/lib/snmppriv.h @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/support.c b/contrib/bsnmp/lib/support.c index 391c152..6a759b3 100644 --- a/contrib/bsnmp/lib/support.c +++ b/contrib/bsnmp/lib/support.c @@ -1,10 +1,10 @@ -/* +/* * Copyright (C) 2004 * Hartmut Brandt. * All rights reserved. - * + * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/contrib/bsnmp/lib/support.h b/contrib/bsnmp/lib/support.h index 415c85b..29dbe4d 100644 --- a/contrib/bsnmp/lib/support.h +++ b/contrib/bsnmp/lib/support.h @@ -4,7 +4,7 @@ * All rights reserved. * * Author: Harti Brandt <harti@freebsd.org> - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -13,7 +13,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |