Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-6]: src/common/lib/libc/gen Pull up following revision(s) (reques...
details: https://anonhg.NetBSD.org/src/rev/f0960bf648e6
branches: netbsd-6
changeset: 776732:f0960bf648e6
user: msaitoh <msaitoh%NetBSD.org@localhost>
date: Mon Oct 27 08:19:33 2014 +0000
description:
Pull up following revision(s) (requested by riastradh in ticket #1142):
common/lib/libc/gen/rb.c: revision 1.12
common/lib/libc/gen/rb.c: revision 1.13
Fix failure case in rb_tree_find_node_leq/geq.
Return NULL, not `NULL - offset'.
XXX pullup to netbsd-5, netbsd-6, netbsd-7
Remove enclosing parens on return.
diffstat:
common/lib/libc/gen/rb.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diffs (40 lines):
diff -r 083f44a3f9ae -r f0960bf648e6 common/lib/libc/gen/rb.c
--- a/common/lib/libc/gen/rb.c Mon Oct 27 06:25:19 2014 +0000
+++ b/common/lib/libc/gen/rb.c Mon Oct 27 08:19:33 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rb.c,v 1.11 2011/06/20 09:11:16 mrg Exp $ */
+/* $NetBSD: rb.c,v 1.11.4.1 2014/10/27 08:19:33 msaitoh Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -39,10 +39,10 @@
#else
#define KASSERT(s) do { } while (/*CONSTCOND*/ 0)
#endif
-__RCSID("$NetBSD: rb.c,v 1.11 2011/06/20 09:11:16 mrg Exp $");
+__RCSID("$NetBSD: rb.c,v 1.11.4.1 2014/10/27 08:19:33 msaitoh Exp $");
#else
#include <lib/libkern/libkern.h>
-__KERNEL_RCSID(0, "$NetBSD: rb.c,v 1.11 2011/06/20 09:11:16 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rb.c,v 1.11.4.1 2014/10/27 08:19:33 msaitoh Exp $");
#endif
#ifdef _LIBC
@@ -145,7 +145,7 @@
parent = parent->rb_nodes[diff < 0];
}
- return RB_NODETOITEM(rbto, last);
+ return last == NULL ? NULL : RB_NODETOITEM(rbto, last);
}
void *
@@ -166,7 +166,7 @@
parent = parent->rb_nodes[diff < 0];
}
- return RB_NODETOITEM(rbto, last);
+ return last == NULL ? NULL : RB_NODETOITEM(rbto, last);
}
void *
Home |
Main Index |
Thread Index |
Old Index