lomount: correct qsort compare function
PATCH 1/1 lomount: correct qsort compare function
Return the correct value from comparing the operands.
Signed-off-by Andreas Schwab <[email protected]>
--- mount/lomount.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
mount/lomount.c +1 -1
@@ -285,7 +285,7 @@ name2minor(int hasprefix, const char *name)static int cmpnum (const void *p1,const void *p2) { -return (* (int *) p1) > (* (int *) p2); +return (*(int *) p1 > *(int *) p2) - (*(int *) p1 < *(int *) p2); }/*
Signature · 7 lines
1.7.6 -- Andreas Schwab, [email protected] GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."
Karel Zak
maintainerQuoted 3 lines · Andreas Schwab
--- mount/lomount.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
Very good catch! Applied, thanks.
Karel
Signature · 2 lines
Karel Zak <[email protected]> http://karelzak.blogspot.com