Re: [PATCH] Fix compiler warning in ftrace.c

From: Guowen Li
Date: Fri Jun 03 2011 - 00:53:54 EST


Thank you for pointing them out, i will be careful next time. :)

Signed-off-by: Guowen Li <guowen.li.linux@xxxxxxxxx>
----- Original Message -----
From: "Steven Rostedt" <rostedt@xxxxxxxxxxx>
To: "GuoWen Li" <guowen.li.linux@xxxxxxxxx>
Cc: <linux-kernel@xxxxxxxxxxxxxxx>
Sent: Friday, June 03, 2011 10:50 AM
Subject: Re: [PATCH] Fix compiler warning in ftrace.c


> Couple of things:
>
> On Wed, 2011-06-01 at 19:18 +0800, GuoWen Li wrote:
>> kernel/trace/ftrace.c: In function âftrace_regex_write.clone.15â:
>> kernel/trace/ftrace.c:2743:6: warning: âretâ may be used uninitialized in this
>> function
>>
>> Signed-off-by: GuoWen Li
>
> Please add your mail address to your SOB. (I'll fix it)
>
>> ---
>> kernel/trace/ftrace.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
>> index 1ee417f..204b3eb 100644
>> --- a/kernel/trace/ftrace.c
>> +++ b/kernel/trace/ftrace.c
>> @@ -2740,7 +2740,7 @@ static int ftrace_process_regex(struct ftrace_hash
>> *hash,
>> {
>> char *func, *command, *next = buff;
>> struct ftrace_func_command *p;
>> - int ret;
>> + int ret = -EINVAL;
>
> This patch has horrible white space issues. (I fixed it)
>
> -- Steve
>
>
>>
>> func = strsep(&next, ":");
>
>
>¢éì®&Þ~º&¶¬–+-±éÝ¥Šw®žË±Êâmébžìdz¹Þ)í…æèw*jg¬±¨¶‰šŽŠÝj/êäz¹ÞŠà2ŠÞ¨è­Ú&¢)ß«a¶Úþø®G«éh®æj:+v‰¨Šwè†Ù>Wš±êÞiÛaxPjØm¶Ÿÿà -»+ƒùdš_