mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH][resend] scripts/mod/modpost.c: fix commentary accordingly to last changes
@ 2010-08-17 10:36 Andy Shevchenko
  2010-08-23  6:52 ` Américo Wang
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Shevchenko @ 2010-08-17 10:36 UTC (permalink / raw)
  To: linux-kernel; +Cc: Andy Shevchenko, Rusty Russell, Andrew Morton

The last commits
 37ed19d5cce35a40d3913cf9aa208ce9f60db3d7
 5003bab82d56754b27be01eef24495a02e00039d
have introduced new behaviour of sec2annotation() method. However, the
commentary inside the method was left as before. Let's fix it accordingly.

Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Andrew Morton <akpm@linux-foundation.org>
---
 scripts/mod/modpost.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
index 1ec7158..33122ca 100644
--- a/scripts/mod/modpost.c
+++ b/scripts/mod/modpost.c
@@ -1208,6 +1208,9 @@ static Elf_Sym *find_elf_symbol2(struct elf_info *elf, Elf_Addr addr,
  * .cpuinit.data => __cpudata
  * .memexitconst => __memconst
  * etc.
+ *
+ * The memory of returned value has been allocated on a heap. The user of this
+ * method should free it after usage.
 */
 static char *sec2annotation(const char *s)
 {
@@ -1230,7 +1233,7 @@ static char *sec2annotation(const char *s)
 			strcat(p, "data ");
 		else
 			strcat(p, " ");
-		return r; /* we leak her but we do not care */
+		return r;
 	} else {
 		return strdup("");
 	}
-- 
1.6.3.3


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-08-26 11:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-17 10:36 [PATCH][resend] scripts/mod/modpost.c: fix commentary accordingly to last changes Andy Shevchenko
2010-08-23  6:52 ` Américo Wang
2010-08-26 11:56   ` Michal Marek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®