fixed #2497: setSearchPaths bug