Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-4]: src/sys/compat/hpux Pull up revision 1.14 (requested by sim...



details:   https://anonhg.NetBSD.org/src/rev/aa72fd65c739
branches:  netbsd-1-4
changeset: 470886:aa72fd65c739
user:      he <he%NetBSD.org@localhost>
date:      Sat Sep 09 15:53:35 2000 +0000

description:
Pull up revision 1.14 (requested by simonb):
  More carefully check length of user-supplied data, in particular
  make sure we don't overrun the available stack gap in stack gap
  allocations.

diffstat:

 sys/compat/hpux/hpux_file.c |  5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diffs (21 lines):

diff -r 9bad0c0a26cc -r aa72fd65c739 sys/compat/hpux/hpux_file.c
--- a/sys/compat/hpux/hpux_file.c       Sat Sep 09 15:53:13 2000 +0000
+++ b/sys/compat/hpux/hpux_file.c       Sat Sep 09 15:53:35 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: hpux_file.c,v 1.13 1999/02/09 20:21:18 christos Exp $  */
+/*     $NetBSD: hpux_file.c,v 1.13.2.1 2000/09/09 15:53:35 he Exp $    */
 
 /*-
  * Copyright (c) 1996, 1997 The NetBSD Foundation, Inc.
@@ -482,10 +482,9 @@
        int error;
 
        sg = stackgap_init(p->p_emul);
-
+       st = stackgap_alloc(&sg, sizeof (struct stat));
        HPUX_CHECK_ALT_EXIST(p, &sg, SCARG(uap, path));
 
-       st = stackgap_alloc(&sg, sizeof (struct stat));
        SCARG(&sa, ub) = st;
        SCARG(&sa, path) = SCARG(uap, path);
 



Home | Main Index | Thread Index | Old Index