From: Matt Helsley <matthltc@us.ibm.com>
To: Trivial <trivial@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Remove unecessary NULL check in kernel/acct.c
Date: Wed, 24 May 2006 16:28:09 -0700 [thread overview]
Message-ID: <1148513289.6853.1120.camel@stark> (raw)
copy_process() appears to be the only caller of acct_clear_integrals() and
does not pass in NULL task pointers. Remove the unecessary check.
Signed-off-by: Matt Helsley <matthltc@us.ibm.com>
--
kernel/acct.c | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
Index: linux-2.6.17-rc4-mm1/kernel/acct.c
===================================================================
--- linux-2.6.17-rc4-mm1.orig/kernel/acct.c
+++ linux-2.6.17-rc4-mm1/kernel/acct.c
@@ -597,11 +597,9 @@ void acct_update_integrals(struct task_s
* acct_clear_integrals - clear the mm integral fields in task_struct
* @tsk: task_struct whose accounting fields are cleared
*/
void acct_clear_integrals(struct task_struct *tsk)
{
- if (tsk) {
- tsk->acct_stimexpd = 0;
- tsk->acct_rss_mem1 = 0;
- tsk->acct_vm_mem1 = 0;
- }
+ tsk->acct_stimexpd = 0;
+ tsk->acct_rss_mem1 = 0;
+ tsk->acct_vm_mem1 = 0;
}
reply other threads:[~2006-05-24 23:35 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=1148513289.6853.1120.camel@stark \
--to=matthltc@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=trivial@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
Powered by JetHome