From: Junio C Hamano <gitster@pobox•com>
To: Eric Sunshine <sunshine@sunshineco•com>
Cc: Elia Pinto <gitter.spiros@gmail•com>,
Git List <git@vger•kernel.org>,
Karsten Blees <karsten.blees@gmail•com>
Subject: Re: [PATCH] api-trace.txt: fix typo
Date: Tue, 05 Apr 2016 13:49:25 -0700 [thread overview]
Message-ID: <xmqqvb3v233e.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <CAPig+cRO22wVRkrMicxLe=Gw4905QMxnnxM8kvtsMJaFv76Yrg@mail.gmail.com> (Eric Sunshine's message of "Tue, 5 Apr 2016 13:15:45 -0400")
Eric Sunshine <sunshine@sunshineco•com> writes:
> On Tue, Apr 5, 2016 at 6:05 AM, Elia Pinto <gitter.spiros@gmail•com> wrote:
>> The correct api is trace_printf_key
>>
>> Signed-off-by: Elia Pinto <gitter.spiros@gmail•com>
>> ---
>> diff --git a/Documentation/technical/api-trace.txt b/Documentation/technical/api-trace.txt
>> @@ -28,7 +28,7 @@ static struct trace_key trace_foo = TRACE_KEY_INIT(FOO);
>> static void trace_print_foo(const char *message)
>> {
>> - trace_print_key(&trace_foo, message);
>> + trace_printf_key(&trace_foo, message);
>> }
>
> Since you're touching this already, I wonder if it would make sense to
> rewrite this example to avoid the dangerous sending of an arbitrary
> string (which might contain %) to a printf-like function. Like this,
> for example:
>
> trace_printf_key(&trace_foo, "%s", message);
Thanks, will squash in.
prev parent reply other threads:[~2016-04-05 20:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-05 10:05 [PATCH] api-trace.txt: fix typo Elia Pinto
2016-04-05 17:15 ` Eric Sunshine
2016-04-05 20:49 ` Junio C Hamano [this message]
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=xmqqvb3v233e.fsf@gitster.mtv.corp.google.com \
--to=gitster@pobox$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
--cc=gitter.spiros@gmail$(echo .)com \
--cc=karsten.blees@gmail$(echo .)com \
--cc=sunshine@sunshineco$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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