Commit 77a5f871 authored by Ted Lemon's avatar Ted Lemon

Fix up char * -> unsigned char * mismatches.

parent 89619cf9
......@@ -22,7 +22,7 @@
#ifndef lint
static char copyright[] =
"$Id: tree.c,v 1.57 1999/10/06 01:35:44 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998 The Internet Software Consortium. All rights reserved.\n";
"$Id: tree.c,v 1.58 1999/10/07 02:14:06 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
......@@ -1338,10 +1338,10 @@ int evaluate_data_expression (result, packet, lease,
return 0;
}
if (data.len == 1 &&
!strncasecmp (data.data, "a", 1)) {
!strncasecmp ((char *)data.data, "a", 1)) {
s = lease -> ddns_fwd_name;
} else if (data.len == 3 &&
!strncasecmp (data.data, "ptr", 3)) {
!strncasecmp ((char *)data.data, "ptr", 3)) {
s = lease -> ddns_rev_name;
} else {
#if defined (DEBUG_EXPRESSIONS)
......
......@@ -22,7 +22,7 @@
#ifndef lint
static char copyright[] =
"$Id: confpars.c,v 1.85 1999/10/01 03:37:29 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
"$Id: confpars.c,v 1.86 1999/10/07 02:14:09 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
......@@ -1015,7 +1015,8 @@ void parse_host_declaration (cfile, group)
}
go = ((struct group_object *)
hash_lookup (group_name_hash,
val, strlen (val)));
(unsigned char *)val,
strlen (val)));
if (!go) {
parse_warn (cfile, "unknown group %s in host %s",
val, host -> name);
......@@ -1636,7 +1637,8 @@ void parse_group_declaration (cfile, group)
if (group_name_hash) {
t = ((struct group_object *)
hash_lookup (group_name_hash,
name, strlen (name)));
(unsigned char *)name,
strlen (name)));
if (t) {
delete_group (t, 0);
}
......
......@@ -22,7 +22,7 @@
#ifndef lint
static char copyright[] =
"$Id: db.c,v 1.32 1999/10/05 02:44:37 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
"$Id: db.c,v 1.33 1999/10/07 02:14:10 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
......@@ -102,7 +102,8 @@ int write_lease (lease)
}
if (lease -> uid_len) {
int i;
if (db_printable_len (lease -> uid, lease -> uid_len)) {
if (db_printable_len ((char *)lease -> uid,
lease -> uid_len)) {
fprintf (db_file, "\n\tuid \"%*.*s\";",
lease -> uid_len, lease -> uid_len,
lease -> uid);
......@@ -244,7 +245,8 @@ int write_host (host)
if (host -> client_identifier.len) {
int i;
errno = 0;
if (db_printable_len (host -> client_identifier.data,
if (db_printable_len ((char *)
host -> client_identifier.data,
host -> client_identifier.len)) {
fprintf (db_file, "\n\tuid \"%*.*s\";",
host -> client_identifier.len,
......
......@@ -22,7 +22,7 @@
#ifndef lint
static char copyright[] =
"$Id: mdb.c,v 1.6 1999/10/05 18:44:27 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
"$Id: mdb.c,v 1.7 1999/10/07 02:14:10 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
......@@ -409,7 +409,8 @@ isc_result_t delete_group (struct group_object *group, int writep)
if (group_name_hash)
d = ((struct group_object *)
hash_lookup (group_name_hash,
group -> name, strlen (group -> name)));
(unsigned char *)group -> name,
strlen (group -> name)));
else
return ISC_R_INVALIDARG;
if (!d)
......@@ -424,7 +425,8 @@ isc_result_t delete_group (struct group_object *group, int writep)
hash table entry. */
if ((group -> flags & GROUP_OBJECT_DYNAMIC) &&
!(group -> flags & GROUP_OBJECT_STATIC)) {
delete_hash_entry (group_name_hash, group -> name,
delete_hash_entry (group_name_hash,
(unsigned char *)group -> name,
strlen (group -> name));
--group -> refcnt;
} else {
......@@ -455,7 +457,7 @@ isc_result_t supersede_group (struct group_object *group, int writep)
if (group_name_hash) {
t = ((struct group_object *)
hash_lookup (group_name_hash,
group -> name,
(unsigned char *)group -> name,
strlen (group -> name)));
if (t && t != group) {
/* If this isn't a dynamic entry, then we need to flag
......@@ -474,9 +476,10 @@ isc_result_t supersede_group (struct group_object *group, int writep)
if (!(t -> flags & GROUP_OBJECT_DELETED))
delete_group (t, 0);
else {
delete_hash_entry (group_name_hash,
group -> name,
strlen (group -> name));
delete_hash_entry
(group_name_hash,
(unsigned char *)group -> name,
strlen (group -> name));
omapi_object_dereference
((omapi_object_t **)&t,
"supersede_group");
......@@ -492,7 +495,8 @@ isc_result_t supersede_group (struct group_object *group, int writep)
dynamic groups if appropriate. */
if (!t) {
add_hash (group_name_hash,
group -> name, strlen (group -> name),
(unsigned char *)group -> name,
strlen (group -> name),
(unsigned char *)group);
}
......
......@@ -29,7 +29,7 @@
#ifndef lint
static char copyright[] =
"$Id: omapi.c,v 1.13 1999/10/06 19:17:44 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
"$Id: omapi.c,v 1.14 1999/10/07 02:14:10 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
......@@ -724,10 +724,11 @@ isc_result_t dhcp_group_destroy (omapi_object_t *h, char *name)
if (group_name_hash) {
t = ((struct group_object *)
hash_lookup (group_name_hash,
group -> name,
(unsigned char *)group -> name,
strlen (group -> name)));
if (t) {
delete_hash_entry (group_name_hash,
(unsigned char *)
group -> name,
strlen (group -> name));
--group -> refcnt;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment