summaryrefslogtreecommitdiff
path: root/monitor_wrap.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2006-03-31 23:13:02 +1100
committerDamien Miller <djm@mindrot.org>2006-03-31 23:13:02 +1100
commit3f9418893e1254bda3b87e7d3af7029d11b0a6c7 (patch)
tree97662277f300ea1ab8255905b9d5d72a26f7578f /monitor_wrap.c
parentd79b424e8ad424a44119f327e5ab1f79cd35649c (diff)
- 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 'monitor_wrap.c')
-rw-r--r--monitor_wrap.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/monitor_wrap.c b/monitor_wrap.c
index f2fbd99ee..8cfc8cc08 100644
--- a/monitor_wrap.c
+++ b/monitor_wrap.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: monitor_wrap.c,v 1.44 2006/03/25 13:17:02 djm Exp $ */ 1/* $OpenBSD: monitor_wrap.c,v 1.45 2006/03/30 09:58:15 djm Exp $ */
2/* 2/*
3 * Copyright 2002 Niels Provos <provos@citi.umich.edu> 3 * Copyright 2002 Niels Provos <provos@citi.umich.edu>
4 * Copyright 2002 Markus Friedl <markus@openbsd.org> 4 * Copyright 2002 Markus Friedl <markus@openbsd.org>
@@ -52,7 +52,7 @@
52#include "xmalloc.h" 52#include "xmalloc.h"
53#include "atomicio.h" 53#include "atomicio.h"
54#include "monitor_fdpass.h" 54#include "monitor_fdpass.h"
55#include "getput.h" 55#include "misc.h"
56#include "servconf.h" 56#include "servconf.h"
57 57
58#include "auth.h" 58#include "auth.h"
@@ -91,7 +91,7 @@ mm_request_send(int sock, enum monitor_reqtype type, Buffer *m)
91 91
92 debug3("%s entering: type %d", __func__, type); 92 debug3("%s entering: type %d", __func__, type);
93 93
94 PUT_32BIT(buf, mlen + 1); 94 put_u32(buf, mlen + 1);
95 buf[4] = (u_char) type; /* 1st byte of payload is mesg-type */ 95 buf[4] = (u_char) type; /* 1st byte of payload is mesg-type */
96 if (atomicio(vwrite, sock, buf, sizeof(buf)) != sizeof(buf)) 96 if (atomicio(vwrite, sock, buf, sizeof(buf)) != sizeof(buf))
97 fatal("%s: write: %s", __func__, strerror(errno)); 97 fatal("%s: write: %s", __func__, strerror(errno));
@@ -112,7 +112,7 @@ mm_request_receive(int sock, Buffer *m)
112 cleanup_exit(255); 112 cleanup_exit(255);
113 fatal("%s: read: %s", __func__, strerror(errno)); 113 fatal("%s: read: %s", __func__, strerror(errno));
114 } 114 }
115 msg_len = GET_32BIT(buf); 115 msg_len = get_u32(buf);
116 if (msg_len > 256 * 1024) 116 if (msg_len > 256 * 1024)
117 fatal("%s: read: bad msg_len %d", __func__, msg_len); 117 fatal("%s: read: bad msg_len %d", __func__, msg_len);
118 buffer_clear(m); 118 buffer_clear(m);