mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-07-14 23:34:08 +00:00
obs-scripting: Fix compilation warnings on Clang and GCC
* Fix unused-parameter when Python is disabled * Calm PySys_SetArgv deprecation since Python 3.11
This commit is contained in:
parent
d7fade2c44
commit
e13e0937a2
3
deps/obs-scripting/obs-scripting-python.c
vendored
3
deps/obs-scripting/obs-scripting-python.c
vendored
|
@ -1702,7 +1702,10 @@ bool obs_scripting_load_python(const char *python_path)
|
|||
wchar_t *argv[] = {L"", NULL};
|
||||
int argc = sizeof(argv) / sizeof(wchar_t *) - 1;
|
||||
|
||||
PRAGMA_WARN_PUSH
|
||||
PRAGMA_WARN_DEPRECATION
|
||||
PySys_SetArgv(argc, argv);
|
||||
PRAGMA_WARN_POP
|
||||
|
||||
#ifdef DEBUG_PYTHON_STARTUP
|
||||
/* ---------------------------------------------- */
|
||||
|
|
1
deps/obs-scripting/obs-scripting.c
vendored
1
deps/obs-scripting/obs-scripting.c
vendored
|
@ -461,6 +461,7 @@ bool obs_scripting_python_runtime_linked(void)
|
|||
|
||||
void obs_scripting_python_version(char *version, size_t version_length)
|
||||
{
|
||||
UNUSED_PARAMETER(version_length);
|
||||
version[0] = 0;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue