git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] git-send-email: fix handling of special characters

From
Junio C Hamano <gitster@pobox.com>
Date
May 23, 2013, 19:56 UTC
Message-ID
<7vfvxdeahz.fsf@alter.siamese.dyndns.org>
In-Reply-To
<7vk3mpeaok.fsf@alter.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> writes:
Show 10 quoted lines
>> +	my $sanitized_sender = sanitize_address($sender);
>> +	if (defined $author and $author ne $sanitized_sender) {
>>  		$message = "From: $author\n\n$message";
>>  		if (defined $author_encoding) {
>>  			if ($has_content_type) {
>
> ...
> Also, isn't the $sender the same during the whole outer loop that
> iterates over @files?  Do we need to apply sanitize_address() on it
> over and over for each and every logical line in the @header?

Ahh, I think $sender is constant, but this is not for each @header line, but done per @file, so it is a much lessor offence than what I originally thought. The other one does do that inside the loop but if we have a single copy of $sanitized_sender at the very beginning that will become a non-issue.

> This comment also applies to the other patch but they probably
> should become a single patch anyway, I guess?
Previous: Junio C HamanoNext: Michael S. Tsirkin
Message 3 of 6 in “git-send-email: fix handling of special characters”
  1. git-send-email: fix handling of special charactersMichael S. Tsirkin, May 23, 2013
  2. Junio C HamanoMay 23, 2013
  3. Junio C HamanoMay 23, 2013
  4. Michael S. TsirkinMay 23, 2013
  5. Junio C HamanoMay 23, 2013
  6. Michael S. TsirkinMay 23, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.