Skip to content

Commit 4274609

Browse files
authored
bpo-32096: Ensure new embedding test can find the encodings module (GH-4566)
1 parent 53efbf3 commit 4274609

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Programs/_testembed.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,8 @@ static int test_forced_io_encoding(void)
132132

133133
static int test_pre_initialization_api(void)
134134
{
135-
wchar_t *program = Py_DecodeLocale("spam", NULL);
135+
/* Leading "./" ensures getpath.c can still find the standard library */
136+
wchar_t *program = Py_DecodeLocale("./spam", NULL);
136137
if (program == NULL) {
137138
fprintf(stderr, "Fatal error: cannot decode program name\n");
138139
return 1;

0 commit comments

Comments
 (0)