gitweb: Remove extra "/" in path names for git_get_project_list
Without this change we get a wrong $pfxlen value and the check_export_ok() checks with with a wrong directory name. Without this patch the below $projects_list fails with gitweb $projects_list = "/tmp/a/b/"; Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>maint
							parent
							
								
									2379d61fa6
								
							
						
					
					
						commit
						6768d6b847
					
				|  | @ -902,6 +902,8 @@ sub git_get_projects_list { | ||||||
| 	if (-d $projects_list) { | 	if (-d $projects_list) { | ||||||
| 		# search in directory | 		# search in directory | ||||||
| 		my $dir = $projects_list; | 		my $dir = $projects_list; | ||||||
|  | 		# remove the trailing "/" | ||||||
|  | 		$dir =~ s!/+$!!; | ||||||
| 		my $pfxlen = length("$dir"); | 		my $pfxlen = length("$dir"); | ||||||
|  |  | ||||||
| 		File::Find::find({ | 		File::Find::find({ | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue
	
	 Aneesh Kumar K.V
						Aneesh Kumar K.V