mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: barebox@lists.infradead.org
Cc: jbe@pengutronix.de
Subject: [PATCH 2/2] glob: fix GLOB_SORT
Date: Fri,  3 Aug 2012 08:30:35 +0200	[thread overview]
Message-ID: <1343975435-5948-2-git-send-email-s.hauer@pengutronix.de> (raw)
In-Reply-To: <1343975435-5948-1-git-send-email-s.hauer@pengutronix.de>

The arguments to collated_compare are actually pointers to
pointers to char, not pointers to char.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 lib/glob.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/glob.c b/lib/glob.c
index c4c6067..1b0137b 100644
--- a/lib/glob.c
+++ b/lib/glob.c
@@ -78,8 +78,8 @@ int glob_pattern_p(const char *pattern, int quote)
 /* Do a collated comparison of A and B.  */
 static int collated_compare(const void *a, const void *b)
 {
-	const char *s1 = a;
-	const char *s2 = b;
+	const char *const s1 = *(const char *const *)a;
+	const char *const s2 = *(const char *const *)b;
 
 	if (s1 == s2)
 		return 0;
-- 
1.7.10.4


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2012-08-03  6:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-03  6:30 [PATCH 1/2] qsort: Fix wrong check Sascha Hauer
2012-08-03  6:30 ` Sascha Hauer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1343975435-5948-2-git-send-email-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=jbe@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox