citrun

watch C/C++ source code execute
Log | Files | Refs | LICENSE

commit 55f29eae52ad04c48e67503b50c319bddc1468ff
parent a482a30e06ff72e65f1ab5aa97da89d108f17082
Author: Kyle Milz <kyle@windows.krwm.net>
Date:   Wed,  4 Jan 2017 17:43:31 -0800

inst: only append .exe if it isn't there already

Diffstat:
Minst_frontend.cc | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/inst_frontend.cc b/inst_frontend.cc @@ -434,7 +434,9 @@ InstFrontend::fork_compiler() char real_cc[MAX_PATH]; std::strcpy(real_cc, m_args[0]); - std::strcat(real_cc, ".exe"); + + if (!ends_with(real_cc, ".exe") && !ends_with(real_cc, ".EXE")) + std::strcat(real_cc, ".exe"); PathFindOnPathA(real_cc, NULL);