Fix Jump-To-Definition bug: trying to open new file when search fails.

Only try to open different file when search succeeds.