Skip to content

Commit e2d78f1

Browse files
committed
src/goDebug: fix noDebug mode for windows
On windows, the executable file has to have '.exe' extension. Add the extension when building the program in noDebug mode. Updates #918 Change-Id: Icddf6c2dced50f885e1dd27fc685a14ea54d52e1 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/274872 Trust: Suzy Mueller <suzmue@golang.org> Trust: Hyang-Ah Hana Kim <hyangah@gmail.com> Run-TryBot: Suzy Mueller <suzmue@golang.org> Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
1 parent e8d462e commit e2d78f1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/debugAdapter/goDebug.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import {
3131
import { DebugProtocol } from 'vscode-debugprotocol';
3232
import { parseEnvFiles } from '../utils/envUtils';
3333
import {
34+
correctBinname,
3435
envPath,
3536
expandFilePathInOutput,
3637
fixDriveCasingInWindows,
@@ -482,8 +483,7 @@ export class Delve {
482483
if (mode === 'debug') {
483484
this.noDebug = true;
484485
const build = ['build'];
485-
486-
const output = path.join(os.tmpdir(), 'out');
486+
const output = path.join(os.tmpdir(), correctBinname('out'));
487487
build.push(`-o=${output}`);
488488

489489
const buildOptions: { [key: string]: any } = { cwd: dirname, env };

0 commit comments

Comments
 (0)