fix-nut-integer-sizes
authorCollectd Packaging Team <team+collectd@tracker.debian.org>
Thu, 7 Dec 2023 14:35:28 +0000 (15:35 +0100)
committerBernd Zeimetz <bzed@debian.org>
Thu, 7 Dec 2023 14:35:28 +0000 (15:35 +0100)
===================================================================

Gbp-Pq: Name fix-nut-integer-sizes

src/nut.c

index 579ecb7ccc780c554f01adec164d7df97a40e762..f4362e38b2d3bd1a3c110df3d4fb745bed931a9e 100644 (file)
--- a/src/nut.c
+++ b/src/nut.c
@@ -46,7 +46,7 @@ struct nut_ups_s {
   collectd_upsconn_t *conn;
   char *upsname;
   char *hostname;
-  int port;
+  uint16_t port;
   nut_ups_t *next;
 };
 
@@ -250,7 +250,7 @@ static int nut_read(user_data_t *user_data) {
   const char *query[3] = {"VAR", ups->upsname, NULL};
   unsigned int query_num = 2;
   char **answer;
-  unsigned int answer_num;
+  size_t answer_num;
   int status;
 
   /* (Re-)Connect if we have no connection */