]> git.sur5r.net Git - openldap/commitdiff
cast pointer to long instead of int to hopefully avoid
authorKurt Zeilenga <kurt@openldap.org>
Thu, 8 Sep 2005 21:38:20 +0000 (21:38 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Thu, 8 Sep 2005 21:38:20 +0000 (21:38 +0000)
truncation.  Change does at least silence warning.

servers/slapd/config.c

index c736bc9bd45287100f9b706eb9d2f9e176205305..8d44c6c60e6295bffae06f8d941bd248f79b9104 100644 (file)
@@ -286,7 +286,7 @@ int config_set_vals(ConfigTable *Conf, ConfigArgs *c) {
                                c->log, c->msg, 0);
                        return(ARG_BAD_CONF);
                }
-               ptr = (void *)((char *)ptr + (int)Conf->arg_item);
+               ptr = (void *)((char *)ptr + (long)Conf->arg_item);
        } else if (arg_type & ARGS_POINTER) {
                ptr = Conf->arg_item;
        }
@@ -372,7 +372,7 @@ config_get_vals(ConfigTable *cf, ConfigArgs *c)
                                ptr = c->bi->bi_private;
                        else
                                return 1;
-                       ptr = (void *)((char *)ptr + (int)cf->arg_item);
+                       ptr = (void *)((char *)ptr + (long)cf->arg_item);
                } else {
                        ptr = cf->arg_item;
                }