[patch 1/8] fix lib/sort regression test

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

 




The regression test in lib/sort.c is currently worthless because the array that is generated for sorting will be all zeros. This patch fixes things so 
that the array that is generated will contain unsorted integers (that are not all identical) as was probably intended.

Signed-off-by Daniel Dickman <[email protected]>


Signed-off-by: Domen Puncer <[email protected]>
---


 kj-domen/lib/sort.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -puN lib/sort.c~bug-lib_sort lib/sort.c
--- kj/lib/sort.c~bug-lib_sort	2005-04-05 12:57:40.000000000 +0200
+++ kj-domen/lib/sort.c	2005-04-05 12:57:40.000000000 +0200
@@ -90,7 +90,7 @@ int cmpint(const void *a, const void *b)
 
 static int sort_test(void)
 {
-	int *a, i, r = 0;
+	int *a, i, r = 1;
 
 	a = kmalloc(1000 * sizeof(int), GFP_KERNEL);
 	BUG_ON(!a);
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux