Comment 47 for bug 428306

Revision history for this message
In , Mh+mozilla (mh+mozilla) wrote :

(In reply to Chris Coulson from comment #14)
> Created attachment 602368
> Treat distribution/searchplugins as a known location and don't use the full
> path for the search engine ID's
>
> We've been carrying a distro patch for a long time to do the normalize() in
> _loadEnginesFromDir(), and I'd like to be able to drop this at some point.
> Whilst normalize() works for us, it probably wouldn't work in all cases (ie,
> if the application directory can move around and nobody symlinked the
> distribution folder to a stable path).
>
> Would you accept something like the attached patch (which basically treats
> distribution/searchplugins as a known location)?

Interestingly, I have a somehow similar patch in debian, but i treat distribution/searchplugins as [app]/ instead of [distribution]/, because i moved all the default searchplugins there. And I have some additional code to make the transition smoother, although there are apparently some edge cases where that doesn't work quite well.