Re: [PATCH 4/7] Add join_paths() to safely concatenate paths.

2012-09-26 Thread Jonathan Nieder
Hi, Michael G. Schwern wrote: > Otherwise you might wind up with things like... > > my $path1 = undef; > my $path2 = 'foo'; > my $path = $path1 . '/' . $path2; > > creating '/foo'. Or this... > > my $path1 = 'foo/'; > my $path2 = 'bar'; > my $path = $path1 . '/' . $path2;

[PATCH 4/7] Add join_paths() to safely concatenate paths.

2012-07-28 Thread Michael G. Schwern
From: "Michael G. Schwern" Otherwise you might wind up with things like... my $path1 = undef; my $path2 = 'foo'; my $path = $path1 . '/' . $path2; creating '/foo'. Or this... my $path1 = 'foo/'; my $path2 = 'bar'; my $path = $path1 . '/' . $path2; creating 'foo//bar'.