lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1452282361.4028.80.camel@perches.com>
Date:	Fri, 08 Jan 2016 11:46:01 -0800
From:	Joe Perches <joe@...ches.com>
To:	Dan Carpenter <dan.carpenter@...cle.com>
Cc:	linux-kernel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [patch] get_maintainer: handle file names beginning with ./

On Fri, 2016-01-08 at 21:46 +0300, Dan Carpenter wrote:
> On Fri, Jan 08, 2016 at 09:47:07AM -0800, Joe Perches wrote:
> > > > Then maybe you'd also have to consider fully qualified
> > > > file names, tilde expansion, $PWD, and probably a bunch
> > > > of other things too.
> > > 
> > > I don't think you'd "have" to consider those as well, but I won't stand
> > > in your way if you want to...
> > 
> > Half measures aren't generally good enough.
> > 
> 
> Those are fake issues though and I can't imagine how they would affect
> anyone.  My issue was super annoying for me because I was sending find
> output to a script and it was almost mailing the correct people because
> it was using git output.  I had to debug for a long time before I
> spotted the difference between ./drivers/media/radio/wl128x/fmdrv_common.c
> and drivers/media/radio/wl128x/fmdrv_common.c.
> 
> I feel like I have seen this before and just manually added the correct
> mailing lists back.  It's crazy annoying and easy to do.
> 
> > Using a combination of CWnd abs_fast_path and $lk_path
> > is probably better.  $lkpath is set to './' by default.
> 
> I have no idea what this means...  It sounds like a good idea though.
> :)  Please give me Reported-by credit.
> 

Maybe this (probably won't apply because I still haven't
converted from Evolution to something that doesn't futz
up sending text emails)

---
 scripts/get_maintainer.pl | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index cab641a..1873421 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -16,7 +16,9 @@ my $P = $0;
 my $V = '0.26';
 
 use Getopt::Long qw(:config no_auto_abbrev);
+use Cwd;
 
+my $cur_path = fastgetcwd() . '/';
 my $lk_path = "./";
 my $email = 1;
 my $email_usename = 1;
@@ -429,6 +431,8 @@ foreach my $file (@ARGV) {
 	}
     }
     if ($from_filename) {
+	$file =~ s/^\Q${cur_path}\E//;	#strip any absolute path
+	$file =~ s/^\Q${lk_path}\E//;	#or the path to the lk tree
 	push(@files, $file);
 	if ($file ne "MAINTAINERS" && -f $file && ($keywords || $file_emails)) {
 	    open(my $f, '<', $file)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ