diff options
author | djm <djm> | 2006-03-31 12:13:02 +0000 |
---|---|---|
committer | djm <djm> | 2006-03-31 12:13:02 +0000 |
commit | fc2eb2b55b30b849dd54510c8f54a1ee9a3fd0fb (patch) | |
tree | 1594b74ce075a8c339f9d7c41b3ce8f0399a2954 /msg.c | |
parent | a3567315845b2b508ef0419d2215cf36a8107535 (diff) | |
download | openssh-fc2eb2b55b30b849dd54510c8f54a1ee9a3fd0fb.tar.gz |
- djm@cvs.openbsd.org 2006/03/30 09:58:16
[authfd.c bufaux.c deattack.c gss-serv.c mac.c misc.c misc.h]
[monitor_wrap.c msg.c packet.c sftp-client.c sftp-server.c ssh-agent.c]
replace {GET,PUT}_XXBIT macros with functionally similar functions,
silencing a heap of lint warnings. also allows them to use
__bounded__ checking which can't be applied to macros; requested
by and feedback from deraadt@
Diffstat (limited to 'msg.c')
-rw-r--r-- | msg.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,4 +1,4 @@ -/* $OpenBSD: msg.c,v 1.10 2006/03/25 13:17:02 djm Exp $ */ +/* $OpenBSD: msg.c,v 1.11 2006/03/30 09:58:15 djm Exp $ */ /* * Copyright (c) 2002 Markus Friedl. All rights reserved. * @@ -25,10 +25,10 @@ #include "includes.h" #include "buffer.h" -#include "getput.h" #include "log.h" #include "atomicio.h" #include "msg.h" +#include "misc.h" int ssh_msg_send(int fd, u_char type, Buffer *m) @@ -38,7 +38,7 @@ ssh_msg_send(int fd, u_char type, Buffer *m) debug3("ssh_msg_send: type %u", (unsigned int)type & 0xff); - PUT_32BIT(buf, mlen + 1); + put_u32(buf, mlen + 1); buf[4] = type; /* 1st byte of payload is mesg-type */ if (atomicio(vwrite, fd, buf, sizeof(buf)) != sizeof(buf)) { error("ssh_msg_send: write"); @@ -64,7 +64,7 @@ ssh_msg_recv(int fd, Buffer *m) error("ssh_msg_recv: read: header"); return (-1); } - msg_len = GET_32BIT(buf); + msg_len = get_u32(buf); if (msg_len > 256 * 1024) { error("ssh_msg_recv: read: bad msg_len %u", msg_len); return (-1); |