aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2001-04-09 21:23:38 +0000
committerRoland McGrath <roland@gnu.org>2001-04-09 21:23:38 +0000
commit6c2a1e8156930005b7c099611d9ab9a889f6418d (patch)
tree8127622e29982acabd1b68369e479c7962fc95fe
parentdda7bd8459991b0e96a0c8b7c2cb63592083fc3f (diff)
downloadglibc-6c2a1e8156930005b7c099611d9ab9a889f6418d.zip
glibc-6c2a1e8156930005b7c099611d9ab9a889f6418d.tar.gz
glibc-6c2a1e8156930005b7c099611d9ab9a889f6418d.tar.bz2
2001-04-07 Roland McGrath <roland@frob.com>
* mach/msgserver.c (__mach_msg_server_timeout): Add an assert.
-rw-r--r--mach/msgserver.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/mach/msgserver.c b/mach/msgserver.c
index c11ea9a..1234353 100644
--- a/mach/msgserver.c
+++ b/mach/msgserver.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+/* Copyright (C) 1993, 1994, 1995, 1996, 2001 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -49,6 +49,11 @@
/*
* HISTORY
* $Log$
+ * Revision 1.6 2001/04/09 21:23:38 roland
+ * 2001-04-07 Roland McGrath <roland@frob.com>
+ *
+ * * mach/msgserver.c (__mach_msg_server_timeout): Add an assert.
+ *
* Revision 1.5 1996/12/20 01:32:35 drepper
* Update from main archive 961219
*
@@ -83,6 +88,7 @@
#include <mach.h>
#include <mach/mig_errors.h>
#include <stdlib.h> /* For malloc and free. */
+#include <assert.h>
mach_msg_return_t
__mach_msg_server_timeout (boolean_t (*demux) (mach_msg_header_t *request,
@@ -116,6 +122,7 @@ __mach_msg_server_timeout (boolean_t (*demux) (mach_msg_header_t *request,
Pass it to DEMUX for processing. */
(void) (*demux) (&request->Head, &reply->Head);
+ assert (reply->Head.msgh_size <= max_size);
switch (reply->RetCode)
{