Source-Changes-HG archive

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

[src/trunk]: src/sys/compat/common compat_30: Fix thinko in previous.



details:   https://anonhg.NetBSD.org/src/rev/4603cd102e19
branches:  trunk
changeset: 363450:4603cd102e19
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sat Mar 12 20:46:03 2022 +0000

description:
compat_30: Fix thinko in previous.

Let's not go into an infinite loop of stack smashing!

diffstat:

 sys/compat/common/vfs_syscalls_30.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 14273617912c -r 4603cd102e19 sys/compat/common/vfs_syscalls_30.c
--- a/sys/compat/common/vfs_syscalls_30.c       Sat Mar 12 19:26:33 2022 +0000
+++ b/sys/compat/common/vfs_syscalls_30.c       Sat Mar 12 20:46:03 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vfs_syscalls_30.c,v 1.44 2022/03/12 15:54:23 riastradh Exp $   */
+/*     $NetBSD: vfs_syscalls_30.c,v 1.45 2022/03/12 20:46:03 riastradh Exp $   */
 
 /*-
  * Copyright (c) 2005, 2008 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls_30.c,v 1.44 2022/03/12 15:54:23 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls_30.c,v 1.45 2022/03/12 20:46:03 riastradh Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -310,7 +310,7 @@
        }
 
        /* if we squished out the whole block, try again */
-       if (any) {
+       if (!any) {
                if (cookiebuf)
                        free(cookiebuf, M_TEMP);
                cookiebuf = NULL;



Home | Main Index | Thread Index | Old Index