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

Re: [PATCH] send-email: Net::SMTP::starttls was introduced in v3.01 (Re: [BUG] git-send-email broken: Can't locate object method "starttls")

From
Jonathan Nieder <jrnieder@gmail.com>
Date
May 31, 2017, 23:01 UTC
Message-ID
<20170531230156.GE81679@aiede.mtv.corp.google.com>
In-Reply-To
<20170531225708.GE72735@gmail.com>
Eric Biggers wrote:
> On Wed, May 31, 2017 at 03:44:15PM -0700, Jonathan Nieder wrote:
Show 10 quoted lines
>> Subject: send-email: Net::SMTP::starttls was introduced in v3.01
>>
>> We cannot rely on the starttls method being present in the copy
>> of Net::SMTP shipped with perl until v5.21.5~169 (Update libnet to
>> CPAN version 3.01, 2014-10-10).
>>
>> Reported-by: Brandon Williams <bmwill@google.com>
>> Reported-by: Eric Biggers <ebiggers3@gmail.com>
>> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
>> ---
[...]
Show 13 quoted lines
>> +++ b/git-send-email.perl
>> @@ -1354,7 +1354,7 @@ EOF
>>  		}
>>  
>>  		require Net::SMTP;
>> -		my $use_net_smtp_ssl = version->parse($Net::SMTP::VERSION) < version->parse("1.28");
>> +		my $use_net_smtp_ssl = version->parse($Net::SMTP::VERSION) < version->parse("3.01");
>>  		$smtp_domain ||= maildomain();
>>  
>>  		if ($smtp_encryption eq 'ssl') {
>> -- 
>
> Yes, that solves the problem for me.
Thanks.  Mining through https://github.com/gbarr/perl-libnet, I find
  $ git log -Sstarttls
[...]
  commit b4a7a274a7fe5344c154abc4b3fdd7c446d36370
  Author: Steffen Ullrich <Steffen_Ullrich@genua.de>
  Date:   Fri May 9 23:15:48 2014 +0200
      SSL and IPv6 support for Net::SMTP
  $ git show b4a7a274a7fe5344c154abc4b3fdd7c446d36370
[...]
  diff --git a/Net/SMTP.pm b/Net/SMTP.pm
  index 705b5c5..fcc124f 100644
  --- a/Net/SMTP.pm
  +++ b/Net/SMTP.pm
  @@ -18,7 +18,31 @@ use Net::Config;
 
   $VERSION = "2.33";
[...]
  $ git log -p --ancestry-path b4a7a274a7fe5344c154abc4b3fdd7c446d36370..HEAD  -- Net/SMTP.pm
[...]
  commit 67b37d5c7118f9af50e5a5a00c242992caba3b8d
  Author: Steve Hay <steve.m.hay@googlemail.com>
  Date:   Mon Jun 2 14:13:55 2014 +0100
      Bump $VERSION in changed modules
  diff --git a/Net/SMTP.pm b/Net/SMTP.pm
  index 4496f6f..9dfaadf 100644
  --- a/Net/SMTP.pm
  +++ b/Net/SMTP.pm
  @@ -16,7 +16,7 @@ use IO::Socket;
   use Net::Cmd;
   use Net::Config;
   
  -$VERSION = "2.34";
  +$VERSION = "2.35";
   
   # Code for detecting if we can use SSL
   my $ssl_class = eval {
I think 2.35 is the correct minimum version.
Jonathan
Previous: Eric BiggersNext: Jonathan Nieder
Message 5 of 6 in “[BUG] git-send-email broken: Can't locate object method "starttls"”
  1. Eric BiggersMay 31, 2017
  2. send-email: Net::SMTP::starttls was introduced in v3.01 (Re: [BUG] git-send-email broken: Can't locate object method "starttls")Jonathan Nieder, May 31, 2017
  3. Junio C HamanoMay 31, 2017
  4. Eric BiggersMay 31, 2017
  5. Jonathan NiederMay 31, 2017
  6. send-email: Net::SMTP::starttls was introduced in v2.34 (Re: [BUG] git-send-email broken: Can't locate object method "starttls")Jonathan Nieder, Jun 1, 2017

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.