public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jesper Juhl <jesper.juhl@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: jesper.juhl@gmail.com, Rickard Faith <faith@redhat.com>
Subject: [PATCH] fix warning: no return statement in function returning non-void in kernel/audit.c
Date: Mon, 11 Sep 2006 17:15:16 +0200	[thread overview]
Message-ID: <200609111715.17080.jesper.juhl@gmail.com> (raw)


kauditd_thread() is being used in a call to kthread_run(). kthread_run() expects
a function returning 'int' which is also how kauditd_thread() is declared. Unfortunately
kauditd_thread() neglects to return a value which results in this complaint from gcc :

  kernel/audit.c:372: warning: no return statement in function returning non-void

Easily fixed by just adding a 'return 0;' to kauditd_thread().


Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
---

 kernel/audit.c |    1 +
 1 file changed, 1 insertion(+)

--- linux-2.6.18-rc6-git3-orig/kernel/audit.c	2006-09-11 10:46:11.092786000 +0200
+++ linux-2.6.18-rc6-git3/kernel/audit.c	2006-09-11 17:08:00.888216381 +0200
@@ -369,6 +369,7 @@ static int kauditd_thread(void *dummy)
 			remove_wait_queue(&kauditd_wait, &wait);
 		}
 	}
+	return 0;
 }
 
 int audit_send_list(void *_dest)




             reply	other threads:[~2006-09-11 15:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-11 15:15 Jesper Juhl [this message]
2006-09-11 16:03 ` [PATCH] fix warning: no return statement in function returning non-void in kernel/audit.c Dave Jones
2006-09-11 19:22   ` Jesper Juhl
2006-09-11 20:23     ` Dave Jones
2006-09-11 22:56 ` Horst H. von Brand
2006-09-12  8:59   ` Jesper Juhl

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=200609111715.17080.jesper.juhl@gmail.com \
    --to=jesper.juhl@gmail.com \
    --cc=faith@redhat.com \
    --cc=linux-kernel@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