From b2b4b45f7169949112c5d6e8e904a434ff60fa6e Mon Sep 17 00:00:00 2001 From: reyk Date: Tue, 4 Apr 2017 15:50:29 +0000 Subject: [PATCH] constify pc_remote and pc_circuit OK rzalamena@ --- usr.sbin/dhcrelay/dhcpd.h | 6 +++--- usr.sbin/dhcrelay/dhcrelay.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/usr.sbin/dhcrelay/dhcpd.h b/usr.sbin/dhcrelay/dhcpd.h index ca690e37eee..239f6053b04 100644 --- a/usr.sbin/dhcrelay/dhcpd.h +++ b/usr.sbin/dhcrelay/dhcpd.h @@ -1,4 +1,4 @@ -/* $OpenBSD: dhcpd.h,v 1.21 2017/03/16 09:17:20 rzalamena Exp $ */ +/* $OpenBSD: dhcpd.h,v 1.22 2017/04/04 15:50:29 reyk Exp $ */ /* * Copyright (c) 2004 Henning Brauer @@ -56,9 +56,9 @@ struct packet_ctx { struct sockaddr_storage pc_src; struct sockaddr_storage pc_dst; - u_int8_t *pc_circuit; + const char *pc_circuit; int pc_circuitlen; - u_int8_t *pc_remote; + const char *pc_remote; int pc_remotelen; }; diff --git a/usr.sbin/dhcrelay/dhcrelay.c b/usr.sbin/dhcrelay/dhcrelay.c index bc2d7d7ddb0..161d289ad1d 100644 --- a/usr.sbin/dhcrelay/dhcrelay.c +++ b/usr.sbin/dhcrelay/dhcrelay.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dhcrelay.c,v 1.61 2017/03/16 09:17:20 rzalamena Exp $ */ +/* $OpenBSD: dhcrelay.c,v 1.62 2017/04/04 15:50:29 reyk Exp $ */ /* * Copyright (c) 2004 Henning Brauer @@ -567,7 +567,7 @@ relay_agentinfo(struct packet_ctx *pc, struct interface_info *intf, return; if (rai_remote != NULL) { - pc->pc_remote = (u_int8_t *)rai_remote; + pc->pc_remote = rai_remote; pc->pc_remotelen = strlen(rai_remote); } else pc->pc_remotelen = 0; @@ -590,7 +590,7 @@ relay_agentinfo(struct packet_ctx *pc, struct interface_info *intf, sizeof(sin->sin_addr); } } else { - pc->pc_circuit = (u_int8_t *)rai_circuit; + pc->pc_circuit = rai_circuit; pc->pc_circuitlen = strlen(rai_circuit); } } -- 2.20.1