Corrrect source file loading

(cherry picked from commit 5864a2382f609a7f9689f67f511a24e8330c80dd)