s4:rpc_server: Fix size types in dcerpc dnsserver
authorAndreas Schneider <asn@samba.org>
Thu, 7 Dec 2017 16:42:02 +0000 (17:42 +0100)
committerJeremy Allison <jra@samba.org>
Tue, 20 Mar 2018 22:16:15 +0000 (23:16 +0100)
This fixes compilation with -Wstrict-overflow=2

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source4/rpc_server/dnsserver/dcerpc_dnsserver.c
source4/rpc_server/dnsserver/dnsdata.c

index 120d4b9a3d72a35b07d636a78a6347c82fb0b5ba..5d3cb9e2a8e3bdbea8856c7c7d4a975bc12ab669 100644 (file)
@@ -1223,9 +1223,9 @@ static WERROR dnsserver_complex_operate_server(struct dnsserver_state *dsstate,
 {
        int valid_operation = 0;
        struct dnsserver_zone *z, **zlist;
-       int zcount;
+       size_t zcount;
        bool found1, found2, found3, found4;
-       int i;
+       size_t i;
 
        if (strcasecmp(operation, "QueryDwordProperty") == 0) {
                if (typeid_in == DNSSRV_TYPEID_LPSTR) {
index c300643351564ae8ebf980b926a61556bc807a4b..8080fa480b284329a06cb5cc3b7edce105ff2274 100644 (file)
@@ -96,7 +96,7 @@ struct IP4_ARRAY *dns_addr_array_to_ip4_array(TALLOC_CTX *mem_ctx,
                                              struct DNS_ADDR_ARRAY *ip)
 {
        struct IP4_ARRAY *ret;
-       int i, count, curr;
+       size_t i, count, curr;
 
        if (ip == NULL) {
                return NULL;