author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Sat, 1 Jul 2017 13:09:40 +0000 (15:09 +0200) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Sat, 1 Jul 2017 13:09:40 +0000 (15:09 +0200) | ||
commit | 0c84688fe1ade967b1a0dfed58519f1ae9f83157 | |
tree | 331291dd6df9f4136c3208cbb142adf1a1f27efe | tree | snapshot |
parent | 7c7cb54633305308ac2e443f4eb7325176889b48 | commit | diff |
snmp_agent plugin: fix a few build warnings
```
CC src/snmp_agent_la-snmp_agent.lo
src/snmp_agent.c:166:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:190:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:289:37: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (i = 0; i < key_len && offset < oid->oid_len; i++)
~~~~~~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:355:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++)
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:420:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:429:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:440:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:532:20: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
assert(oid_index < values_num);
~~~~~~~~~ ^ ~~~~~~~~~~
/usr/include/assert.h:89:5: note: expanded from macro 'assert'
((expr) \
^~~~
src/snmp_agent.c:584:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:768:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:806:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:821:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:1287:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
13 warnings generated.
```
```
CC src/snmp_agent_la-snmp_agent.lo
src/snmp_agent.c:166:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:190:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:289:37: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (i = 0; i < key_len && offset < oid->oid_len; i++)
~~~~~~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:355:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++)
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:420:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:429:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:440:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < (*dd)->oids_len; i++)
~ ^ ~~~~~~~~~~~~~~~
src/snmp_agent.c:532:20: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
assert(oid_index < values_num);
~~~~~~~~~ ^ ~~~~~~~~~~
/usr/include/assert.h:89:5: note: expanded from macro 'assert'
((expr) \
^~~~
src/snmp_agent.c:584:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:768:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:806:25: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:821:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
src/snmp_agent.c:1287:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < dd->oids_len; i++) {
~ ^ ~~~~~~~~~~~~
13 warnings generated.
```
src/snmp_agent.c | diff | blob | history |