mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-16 20:05:14 +02:00
escape % in file_tag_query as it is ultimately embedded in a sprintf
This commit is contained in:
parent
adebc2793e
commit
0cf2e051bb
2 changed files with 5 additions and 1 deletions
|
@ -1306,6 +1306,10 @@ function file_tag_decode($s) {
|
|||
}
|
||||
|
||||
function file_tag_file_query($table,$s,$type = 'file') {
|
||||
|
||||
// this is ultimately going into a vsprintf
|
||||
$s = str_replace('%','%%',$s);
|
||||
|
||||
if($type == 'file')
|
||||
$str = preg_quote( '[' . file_tag_encode($s) . ']' );
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue