Project:Swish-E Indexer
Version:4.6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

not sure why users are naming their files to start with a space but it's causing errors in swish-e. for example, if the filename is " myfile.doc" with size of 1234 then the function swish_search assigns the following:

$title = ' myfile.doc" 1234'
$file_size = 'myfile.doc" 1234'

the error shows up in swishnodelist_render with an incorrect syntax for the sql statement. did a quick fix by changing the assignment statement for $j in swish_search function to

$j = strrpos($result, '" ');

that is, the first occurence from the right.

this is probably better handled in the upload module by trimming whitespaces from the filename, but not sure.

Comments

#1

Status:active» fixed

#2

filenames are now possible to be indexed when they begin with a space

#3

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.