summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2002-02-17 18:33:07 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2002-02-17 18:33:07 +0000
commitdb530f9f850ee292c336ac25539fa14cd7464878 (patch)
tree94478de5f70485665ed4e145ad223b11025bf655 /usr.sbin
parent7e554e176e12c53d6da3c5b9cfb7e6c4e6af4d7b (diff)
fix LP64 bug; ura@hiru.aoba.yokohama.jp
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/dhcp/common/convert.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/usr.sbin/dhcp/common/convert.c b/usr.sbin/dhcp/common/convert.c
index c08e9d3a09f..12afe87a40a 100644
--- a/usr.sbin/dhcp/common/convert.c
+++ b/usr.sbin/dhcp/common/convert.c
@@ -46,36 +46,36 @@
u_int32_t getULong (buf)
unsigned char *buf;
{
- unsigned long ibuf;
+ u_int32_t ibuf;
- memcpy (&ibuf, buf, sizeof (u_int32_t));
+ memcpy (&ibuf, buf, sizeof (ibuf));
return ntohl (ibuf);
}
int32_t getLong (buf)
unsigned char *buf;
{
- long ibuf;
+ int32_t ibuf;
- memcpy (&ibuf, buf, sizeof (int32_t));
+ memcpy (&ibuf, buf, sizeof (ibuf));
return ntohl (ibuf);
}
u_int16_t getUShort (buf)
unsigned char *buf;
{
- unsigned short ibuf;
+ u_int16_t ibuf;
- memcpy (&ibuf, buf, sizeof (u_int16_t));
+ memcpy (&ibuf, buf, sizeof (ibuf));
return ntohs (ibuf);
}
int16_t getShort (buf)
unsigned char *buf;
{
- short ibuf;
+ int16_t ibuf;
- memcpy (&ibuf, buf, sizeof (int16_t));
+ memcpy (&ibuf, buf, sizeof (ibuf));
return ntohs (ibuf);
}