Re: [PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-14 Thread Chen Gang F T
On 2013年04月12日 22:29, Serge E. Hallyn wrote:
> Quoting Chen Gang (gang.c...@asianux.com):
>> > 
>> >   after kfree acct, also set ns->bacct to NULL.
>> > 
>> > Signed-off-by: Chen Gang 
> Acked-by: Serge Hallyn 
> 

  thanks.

-- 
Chen Gang

Flying Transformer
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-14 Thread Chen Gang F T
On 2013年04月12日 22:29, Serge E. Hallyn wrote:
 Quoting Chen Gang (gang.c...@asianux.com):
  
after kfree acct, also set ns-bacct to NULL.
  
  Signed-off-by: Chen Gang gang.c...@asianux.com
 Acked-by: Serge Hallyn serge.hal...@canonical.com
 

  thanks.

-- 
Chen Gang

Flying Transformer
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-12 Thread Serge E. Hallyn
Quoting Chen Gang (gang.c...@asianux.com):
> 
>   after kfree acct, also set ns->bacct to NULL.
> 
> Signed-off-by: Chen Gang 

Acked-by: Serge Hallyn 

> ---
>  kernel/acct.c |1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/kernel/acct.c b/kernel/acct.c
> index 85389fe..91a23eb 100644
> --- a/kernel/acct.c
> +++ b/kernel/acct.c
> @@ -332,6 +332,7 @@ void acct_exit_ns(struct pid_namespace *ns)
>   spin_lock(_lock);
>   if (acct->file != NULL)
>   acct_file_reopen(acct, NULL, NULL);
> + ns->bacct = NULL;
>   spin_unlock(_lock);
>  
>   kfree(acct);
> -- 
> 1.7.7.6
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-12 Thread Serge E. Hallyn
Quoting Chen Gang (gang.c...@asianux.com):
 
   after kfree acct, also set ns-bacct to NULL.
 
 Signed-off-by: Chen Gang gang.c...@asianux.com

Acked-by: Serge Hallyn serge.hal...@canonical.com

 ---
  kernel/acct.c |1 +
  1 files changed, 1 insertions(+), 0 deletions(-)
 
 diff --git a/kernel/acct.c b/kernel/acct.c
 index 85389fe..91a23eb 100644
 --- a/kernel/acct.c
 +++ b/kernel/acct.c
 @@ -332,6 +332,7 @@ void acct_exit_ns(struct pid_namespace *ns)
   spin_lock(acct_lock);
   if (acct-file != NULL)
   acct_file_reopen(acct, NULL, NULL);
 + ns-bacct = NULL;
   spin_unlock(acct_lock);
  
   kfree(acct);
 -- 
 1.7.7.6
 --
 To unsubscribe from this list: send the line unsubscribe linux-kernel in
 the body of a message to majord...@vger.kernel.org
 More majordomo info at  http://vger.kernel.org/majordomo-info.html
 Please read the FAQ at  http://www.tux.org/lkml/
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-10 Thread Chen Gang

  after kfree acct, also set ns->bacct to NULL.

Signed-off-by: Chen Gang 
---
 kernel/acct.c |1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/kernel/acct.c b/kernel/acct.c
index 85389fe..91a23eb 100644
--- a/kernel/acct.c
+++ b/kernel/acct.c
@@ -332,6 +332,7 @@ void acct_exit_ns(struct pid_namespace *ns)
spin_lock(_lock);
if (acct->file != NULL)
acct_file_reopen(acct, NULL, NULL);
+   ns->bacct = NULL;
spin_unlock(_lock);
 
kfree(acct);
-- 
1.7.7.6
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] kernel: acct: kfree, also set related variable to NULL after kfree

2013-04-10 Thread Chen Gang

  after kfree acct, also set ns-bacct to NULL.

Signed-off-by: Chen Gang gang.c...@asianux.com
---
 kernel/acct.c |1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/kernel/acct.c b/kernel/acct.c
index 85389fe..91a23eb 100644
--- a/kernel/acct.c
+++ b/kernel/acct.c
@@ -332,6 +332,7 @@ void acct_exit_ns(struct pid_namespace *ns)
spin_lock(acct_lock);
if (acct-file != NULL)
acct_file_reopen(acct, NULL, NULL);
+   ns-bacct = NULL;
spin_unlock(acct_lock);
 
kfree(acct);
-- 
1.7.7.6
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/