- rename some symbols (state bs->bt), callbacks prefix with libbt
- assemble the line with strappend-like functions and write() just the
result
- flush the output after backtrace_symbols_fd() in case that the later
calls fail to have at least something output
- write_number->append_number for point 2 + tid write
Corrected various spelling mistakes in comments, documentation, and
variable names across the project. Changes include:
- Documentation files (CONTRIBUTING.md, README.md, etc.)
- Source code comments in C/C++ files
- Function parameter names and descriptions
No functional changes were made.
The actual value (5,2,1)/5 didn't match peach fuzz (255,190,152)/255
but the rather closest color is Tomato (255,99,71)/255.
The T_DARKER_ORANGE is poorly defined but its value (3,1,0)/5 matches
approximately the X11 color Saddle Brown (139,69,19)/255.
It can be used in place of other network-related headers, not just for
htonl and family.
+ compat for fd_t and INVALID_SOCKET (that has been in config_*.h)
Since the function can be called from the signal handler, there must
not be any call to signal unsafe function (see signal-safety(7)).
Actually, this is not just a fix of a possible problem but it caused
activelly problems within the reflector when 2 signals were raised one
shortly after anotner. Was stuck at following (snippet):
```
std::unique_lock<std::mutex>::unique_lock(std::mutex&) at /usr/include/c++/14.1.1/bits/unique_lock.h:74
(inlined by) state_root::broadcast_should_exit() at /home/martin/Projects/ultragrid/src/host.cpp:533
exit_uv at /home/martin/Projects/ultragrid/src/host.cpp:587
signal_handler(int) at /home/martin/Projects/ultragrid/src/hd-rum-translator/hd-rum-translator.cpp:219
```
Instead of tweaking the getopt manually, use non-permuting version of
getopt (POSIX-compiliant, indicated by leading '+' in optstring).
This is slightly less error-prone and more readable. Althoug still a
bit tweaking is needed - skipping a non-opt (which can be in the middle
of argv if user cmd uses this syntax). Also options for opts that are
not recognized by this getopt (any aother than -O/-V) will appear as
a non-opt.
optind needs to be set to 0 than 1 to reinit its internal state (see
NOTES in man getopt(3)) for getopt_long() in hd-rum-transcode. If not
so, the leading '+' in optstring (== disallowing permutation) won't
be effective.
Do not issue the warning over PowerShell or cmd legacy terminal emulators
in Windows 11. In Window the check doesn't work, because the process
tree is different - the Windows Terminal doesn't have its own process
and it is uv.exe->powershell.exe->exporer.exe.
This improves commit bb2a72f67f.
Although there is cmd/PS in process tree, it may be used just like shell
(eg. when run over SSH) so that the terminal may be eg. some Linux
terminal emulator.
Those terminal emulators block stdout/stderr output when scrolled,
which effectively stops UltraGrid. The behavior doesn't occur in MS
Terminal app, which is encouraged instead.
Note that Windows Terminal still runs cmd.exe or powershell.exe as a shell
while the cmd/PS process can acts like both terminal emulator and
shell. We also do not trigger the warning if UG is run from within
MSYS2 terminal.
CentOS 7 has glibc 2.17 not supporting memfd_create, so use the generic
POSIX solution as for macOS but with a different, non-portable, thread
ID query function (note: gettid() requires glibc 2.30).
Previously, if eg. multiple worker crashed, backtraces were interleaved
- use temporary file to print it. It seems that the new implementation
prints backtrace just from one thread, which shouldn't matter, anyways,
because it is improbable that there are two different crashes at the
same time.
For uninit, screen-capture-recorder-x86.dll calls CoInitialize(0) and
fails because it fails.
Curiously this doesn't occur for register, which should be equivalent.
Get the info from audio lavc in textual form instead with a new API to
querying additional info about codec for user.
The new API will allow adding additional useful information in help,
eg. encoders present.
this updates the commit a0dd6b9b85
This may be useful sometimes, eg. when comparing 2 versions where one
has some param and the other not. Or if the param presence is depending
on selected feature (eg. `--param debug-dump=`).
With current zfec code, fec_init() needs to be called prior to fec_new(),
otherwise the later one returns NULL.
\+ updated submodule to the current zfec version (requiring fec_init();
but UG will compile with the older zfec version as well)