=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/msg.c,v retrieving revision 1.8.2.1 retrieving revision 1.9 diff -u -r1.8.2.1 -r1.9 --- src/usr.bin/ssh/msg.c 2006/10/06 03:19:32 1.8.2.1 +++ src/usr.bin/ssh/msg.c 2006/03/19 18:51:18 1.9 @@ -1,4 +1,3 @@ -/* $OpenBSD: msg.c,v 1.8.2.1 2006/10/06 03:19:32 brad Exp $ */ /* * Copyright (c) 2002 Markus Friedl. All rights reserved. * @@ -22,21 +21,13 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "includes.h" -#include -#include - -#include -#include -#include -#include -#include - #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) @@ -46,7 +37,7 @@ debug3("ssh_msg_send: type %u", (unsigned int)type & 0xff); - put_u32(buf, mlen + 1); + PUT_32BIT(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"); @@ -72,7 +63,7 @@ error("ssh_msg_recv: read: header"); return (-1); } - msg_len = get_u32(buf); + msg_len = GET_32BIT(buf); if (msg_len > 256 * 1024) { error("ssh_msg_recv: read: bad msg_len %u", msg_len); return (-1);