Instead of erroring out completely when it can't determine if the
certificate is valid, proceed anyway. This matches how web browsers
treat failed cert revocation checks. schannel just has somewhat
paranoid defaults.
os_readdir might return an empty path if the OS filename doesn't fit
into the buffer after os_wcs_to_utf8. If this empty path is then passed
to os_get_path_extension it causes a crash.
Previously, any short write would be treated elsewhere as a failure. The
easiest solution is to have pipe_write() automatically retry until either
it's written everything, or it couldn't write anything at all.
A plugin that saves whitespace-only data would crash OBS on startup as
the whitespace stripping would send the string length negative. While
that bug is fixed in this commit, there is also no good reason that OBS
is stripping whitespace to begin with. All data going into the configs
should be well formed and some plugins legitimately wish to save
whitespace as a config option (eg for search / replace characters).
Previously the assertion required the idx to be smaller than the number
of elements in the darray. This would mean you could not insert anything
at the end of a darray, and would make it impossible to insert an array
into an empty darray.
SIMDE was introduced for aarch64 support, however, the library itself
supports non-SIMD fallback, which allows us provide support to other
platforms without code changes.
There is another world beyond x86. So we can simply enable SIMDE for
processors without SSE2 support.
Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
This uses three methods of obtaining the actual windows version,
RtlGetVersion which is the ntdll version of GetVersionEx that bypasses
the manifest check garbage, looking up the file version of a file that
is most likely to be updated per windows version (ntoskrnl), and the
registry. Of the three values, it chooses the highest windows version
obtained by the three.
Closesobsproject/obs-studio#2294
Code submissions have continually suffered from formatting
inconsistencies that constantly have to be addressed. Using
clang-format simplifies this by making code formatting more consistent,
and allows automation of the code formatting so that maintainers can
focus more on the code itself instead of code formatting.
Ensures that functions loaded by `os_dlsym()` come only from the
specified library that was loaded with `os_dlopen()` rather than the set
of libraries loaded by the specified library.
We can't compare addresses of ComPtr for self-reference directly because
the address-of operator is overloaded, causing a compiler error. This
fix more or less matches the WRL implementation.
Returns the current version number of windows. The lowest byte is the
minor version number, then the next lowest byte is the major version
number. E.g. 0x601 for Windows 7, 0x602 for Windows 8, 0x603 for
Windows 8.1, and 0xA00 for Windows 10.
Certain windows functions may allow 0 as a valid handle value, therefore
INVALID_HANDLE_VALUE is a more appropriate initialization value.
Closesobsproject/obs-studio#1519
The pthread_setname_np manpage states:
The thread name is a meaningful C language string, whose length is
restricted to 16 characters, including the terminating null byte ('\0').
If a config file value is set to a blank value, the value would not be
set and the default value would be used. This fixes a bug where the
user would try to remove the replay buffer prefix, only to have the
prefix be added again next time they start the program.
Caches the frequency of the performance counter. It was supposed to be
caching it already, but it seems that code was unintentionally not
included.
Closesjp9000/obs-studio#1185
When splitting a string in to a string list via stringlist_split, it
would previously allocate memory for each sub-string and again for the
list itself. This optimizes that function to use a single contiguous
chunk of memory for the sake of access optimization and memory
allocation efficiency.
Adds circlebuf_push_front_zero and circlebuf_push_back_zero to
conveniently push zeroed data to the front/back of the buffer without
having to create an intermediary buffer to accomplish the same thing.