https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119756
--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-15 branch has been updated by Nathaniel Shead <[email protected]>: https://gcc.gnu.org/g:56009066d29a328757fb9ed64a6033838e516584 commit r15-10851-g56009066d29a328757fb9ed64a6033838e516584 Author: Nathaniel Shead <[email protected]> Date: Sun Feb 22 00:32:00 2026 +1100 libcpp: Fix reading from stdin with -fsearch-include-path [PR119756] When using -fsearch-include-path, we prepend the result of search_path_head to the provided filenames, which for non-absolute paths will return "./". At this point, stdin is represented by the empty string, and so prepending "./" confuses 'open_file'. This patch fixes the issue by treating stdin as-if it were an absolute path. PR c++/119756 libcpp/ChangeLog: * files.cc (search_path_head): Also treat empty string (stdin) as an absolute path. Signed-off-by: Nathaniel Shead <[email protected]> Reviewed-by: Jason Merrill <[email protected]> (cherry picked from commit 81b437bad0925ddaae6a75a72759edb18cc4f438)
