From: Alecs King <alecsk@gmail.com>
To: linux-sparse <linux-sparse@vger.kernel.org>
Subject: [PATCH] fix sparse warnings
Date: Sat, 31 Dec 2005 15:21:18 +0800 [thread overview]
Message-ID: <20051231072118.GA3574@localhost> (raw)
sort.c:192:5: warning: mixing declarations and code
sort.c:234:2: warning: mixing declarations and code
Signed-off-by: Alecs King <alecsk@gmail.com>
diff --git a/sort.c b/sort.c
index c2ac8b7..749339a 100644
--- a/sort.c
+++ b/sort.c
@@ -186,10 +186,10 @@ merge_block_seqs (struct ptr_list *b1, i
// Element from b2 is smaller
buffer[nbuf++] = d2;
if (++i2 >= b2->nr) {
+ struct ptr_list *l = b2;
BEEN_THERE('M');
// Ok, we finished with b2. Pull it out
// and plug it in before b1.
- struct ptr_list *l = b2;
b2 = b2->next;
b2->prev = l->prev;
@@ -224,14 +224,13 @@ merge_block_seqs (struct ptr_list *b1, i
void sort_list(struct ptr_list **plist, int (*cmp)(const void *, const void *))
{
- struct ptr_list *head = *plist;
+ struct ptr_list *head = *plist, *list = head;
int blocks = 1;
if (!head)
return;
// Sort all the sub-lists
- struct ptr_list *list = head;
do {
array_sort(list->list, list->nr, cmp);
#ifdef PARANOIA
--
Alecs King
reply other threads:[~2005-12-31 7:14 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20051231072118.GA3574@localhost \
--to=alecsk@gmail.com \
--cc=linux-sparse@vger.kernel.org \
/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