Skip to content

Commit f4b49a3

Browse files
committed
Fix issue lava#124
1 parent 7d0e695 commit f4b49a3

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

matplotlibcpp.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,11 @@ struct _interpreter {
153153
Py_SetProgramName(name);
154154
Py_Initialize();
155155

156+
wchar_t const *dummy_args[] = {L"Python", NULL}; // const is needed because literals must not be modified
157+
wchar_t const **argv = dummy_args;
158+
int argc = sizeof(dummy_args)/sizeof(dummy_args[0])-1;
159+
PySys_SetArgv(argc, const_cast<wchar_t **>(argv));
160+
156161
#ifndef WITHOUT_NUMPY
157162
import_numpy(); // initialize numpy C-API
158163
#endif

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy