Merge "Fix compilation on python2"
This commit is contained in:
commit
2ca9238894
@ -621,7 +621,11 @@ bool fm_db_util_sync_event_suppression(void){
|
|||||||
|
|
||||||
Py_SetProgramName(argv[0]);
|
Py_SetProgramName(argv[0]);
|
||||||
Py_Initialize();
|
Py_Initialize();
|
||||||
|
#if PY_MAJOR_VERSION >= 3
|
||||||
|
PySys_SetArgv(argc, py_argv);
|
||||||
|
#else
|
||||||
PySys_SetArgv(argc, argv);
|
PySys_SetArgv(argc, argv);
|
||||||
|
#endif
|
||||||
file = fopen(FM_DB_SYNC_EVENT_SUPPRESSION,"r");
|
file = fopen(FM_DB_SYNC_EVENT_SUPPRESSION,"r");
|
||||||
PyRun_SimpleFile(file, FM_DB_SYNC_EVENT_SUPPRESSION);
|
PyRun_SimpleFile(file, FM_DB_SYNC_EVENT_SUPPRESSION);
|
||||||
fclose(file);
|
fclose(file);
|
||||||
|
Loading…
Reference in New Issue
Block a user