From 3e447f896409696e20466665694410805abbeec8 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Tue, 10 Nov 2009 15:08:57 +0100 Subject: [PATCH] bweb: escape _ % for LIKE search --- gui/bweb/cgi/bresto.pl | 1 + 1 file changed, 1 insertion(+) diff --git a/gui/bweb/cgi/bresto.pl b/gui/bweb/cgi/bresto.pl index 662504f32c..9442a552cb 100755 --- a/gui/bweb/cgi/bresto.pl +++ b/gui/bweb/cgi/bresto.pl @@ -914,6 +914,7 @@ sub fill_table_for_restore foreach my $dirid (@dirid) { my $p = $bvfs->get_path($dirid); + $p =~ s/([%_\\])/\\$1/g; # Escape % and _ for LIKE search $p = $bvfs->dbh_quote($p); push @union, " (SELECT File.JobId, File.FileIndex, File.FilenameId, File.PathId $FileId -- 2.39.5