mirror of
https://gitlab.isc.org/isc-projects/dhcp
synced 2025-08-23 02:17:31 +00:00
Compiler warnings (a few were bugfixes internal to HEAD development) silenced.
[ISC-Bugs #16133]
This commit is contained in:
parent
41c3f761a3
commit
d19e2cf7de
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#ifndef lint
|
#ifndef lint
|
||||||
static char copyright[] =
|
static char copyright[] =
|
||||||
"$Id: parse.c,v 1.110 2006/06/01 20:23:17 dhankins Exp $ Copyright (c) 2004-2006 Internet Systems Consortium. All rights reserved.\n";
|
"$Id: parse.c,v 1.111 2006/06/05 16:42:58 dhankins Exp $ Copyright (c) 2004-2006 Internet Systems Consortium. All rights reserved.\n";
|
||||||
#endif /* not lint */
|
#endif /* not lint */
|
||||||
|
|
||||||
#include "dhcpd.h"
|
#include "dhcpd.h"
|
||||||
@ -1079,7 +1079,7 @@ void parse_option_space_decl (cfile)
|
|||||||
default:
|
default:
|
||||||
parse_warn(cfile, "invalid code width (%d), "
|
parse_warn(cfile, "invalid code width (%d), "
|
||||||
"expecting a 1, 2 or 4.",
|
"expecting a 1, 2 or 4.",
|
||||||
val);
|
tsize);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -1100,7 +1100,7 @@ void parse_option_space_decl (cfile)
|
|||||||
lsize = atoi(val);
|
lsize = atoi(val);
|
||||||
if (lsize != 1 && lsize != 2) {
|
if (lsize != 1 && lsize != 2) {
|
||||||
parse_warn(cfile, "invalid length width (%d) "
|
parse_warn(cfile, "invalid length width (%d) "
|
||||||
"expecting 1 or 2.", val);
|
"expecting 1 or 2.", lsize);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2140,6 +2140,7 @@ void parse_client_lease_declaration PROTO ((struct parse *,
|
|||||||
int parse_option_decl PROTO ((struct option_cache **, struct parse *));
|
int parse_option_decl PROTO ((struct option_cache **, struct parse *));
|
||||||
void parse_string_list PROTO ((struct parse *, struct string_list **, int));
|
void parse_string_list PROTO ((struct parse *, struct string_list **, int));
|
||||||
int parse_ip_addr PROTO ((struct parse *, struct iaddr *));
|
int parse_ip_addr PROTO ((struct parse *, struct iaddr *));
|
||||||
|
int parse_ip_addr_with_subnet(struct parse *, struct iaddrmatch *);
|
||||||
void parse_reject_statement PROTO ((struct parse *, struct client_config *));
|
void parse_reject_statement PROTO ((struct parse *, struct client_config *));
|
||||||
|
|
||||||
/* dhcrelay.c */
|
/* dhcrelay.c */
|
||||||
|
@ -60,7 +60,7 @@ struct hash_bucket {
|
|||||||
hashed_object_t *value;
|
hashed_object_t *value;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef int (*hash_comparator_t)(const void *, const void *, unsigned long);
|
typedef int (*hash_comparator_t)(const void *, const void *, size_t);
|
||||||
|
|
||||||
struct hash_table {
|
struct hash_table {
|
||||||
unsigned hash_count;
|
unsigned hash_count;
|
||||||
@ -152,6 +152,6 @@ void delete_hash_entry (struct hash_table *, const void *,
|
|||||||
int hash_lookup (hashed_object_t **, struct hash_table *,
|
int hash_lookup (hashed_object_t **, struct hash_table *,
|
||||||
const void *, unsigned, const char *, int);
|
const void *, unsigned, const char *, int);
|
||||||
int hash_foreach (struct hash_table *, hash_foreach_func);
|
int hash_foreach (struct hash_table *, hash_foreach_func);
|
||||||
int casecmp (const void *s, const void *t, unsigned long len);
|
int casecmp (const void *s, const void *t, size_t len);
|
||||||
|
|
||||||
#endif /* OMAPI_HASH_H */
|
#endif /* OMAPI_HASH_H */
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#ifndef lint
|
#ifndef lint
|
||||||
static char copyright[] =
|
static char copyright[] =
|
||||||
"$Id: hash.c,v 1.8 2006/06/01 20:23:17 dhankins Exp $ Copyright (c) 2004-2006 Internet Systems Consortium. All rights reserved.\n";
|
"$Id: hash.c,v 1.9 2006/06/05 16:42:59 dhankins Exp $ Copyright (c) 2004-2006 Internet Systems Consortium. All rights reserved.\n";
|
||||||
#endif /* not lint */
|
#endif /* not lint */
|
||||||
|
|
||||||
#include <omapip/omapip_p.h>
|
#include <omapip/omapip_p.h>
|
||||||
@ -52,6 +52,7 @@ find_length(const void *key,
|
|||||||
return 4;
|
return 4;
|
||||||
|
|
||||||
log_fatal("Impossible condition at %s:%d.", MDL);
|
log_fatal("Impossible condition at %s:%d.", MDL);
|
||||||
|
return 0; /* Silence compiler warnings. */
|
||||||
}
|
}
|
||||||
|
|
||||||
int new_hash_table (tp, count, file, line)
|
int new_hash_table (tp, count, file, line)
|
||||||
@ -424,25 +425,25 @@ int hash_foreach (struct hash_table *table, hash_foreach_func func)
|
|||||||
return count;
|
return count;
|
||||||
}
|
}
|
||||||
|
|
||||||
int casecmp (const void *v1, const void *v2, unsigned long len)
|
int casecmp (const void *v1, const void *v2, size_t len)
|
||||||
{
|
{
|
||||||
unsigned i;
|
size_t i;
|
||||||
const char *s = v1;
|
const char *s = v1;
|
||||||
const char *t = v2;
|
const char *t = v2;
|
||||||
|
|
||||||
for (i = 0; i < len; i++)
|
for (i = 0; i < len; i++)
|
||||||
{
|
{
|
||||||
int c1, c2;
|
int c1, c2;
|
||||||
if (isascii (s [i]) && isupper (s [i]))
|
if (isascii(s[i]))
|
||||||
c1 = tolower (s [i]);
|
c1 = tolower(s[i]);
|
||||||
else
|
else
|
||||||
c1 = s [i];
|
c1 = s[i];
|
||||||
|
|
||||||
if (isascii (t [i]) && isupper (t [i]))
|
if (isascii(t[i]))
|
||||||
c2 = tolower (t [i]);
|
c2 = tolower(t[i]);
|
||||||
else
|
else
|
||||||
c2 = t [i];
|
c2 = t[i];
|
||||||
|
|
||||||
if (c1 < c2)
|
if (c1 < c2)
|
||||||
return -1;
|
return -1;
|
||||||
if (c1 > c2)
|
if (c1 > c2)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user