Commit Graph

41 Commits

Author SHA1 Message Date
Martin Piatka
2e53e19e94 export: Return pointer as NULL instead of false 2025-10-17 12:25:00 +02:00
Ben Roeder
a62fe80c3f Fix spelling errors throughout codebase
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.
2025-06-01 18:03:40 +01:00
Martin Pulec
b1cd3166c4 Revert "export: crash if nullptr passed"
This reverts commit 4143900605.

Actaully, the transcoding reflector doesn't set the export module,
so that it will crash with this. Crasing command:
```
hd-rum-transcode 8M 5004 -c lavc -P 6004 100::
```
2024-09-10 09:17:34 +02:00
Martin Pulec
4143900605 export: crash if nullptr passed
The export module is now intended to be initialized always, although
not exporting at that moment, so assert the state presence for
export_audio/export_video.
2024-08-09 09:31:38 +02:00
Martin Pulec
b10cbf5c1c export: small simplification
use pares_options always (even with NULL)
2024-07-01 13:53:29 +02:00
Martin Pulec
894bd3afa6 export: allow opts without directory name
allow `uv --record=limit=3:exit_on_limit` (using autmoatic directory export.<date>)
2024-07-01 13:48:35 +02:00
Martin Pulec
e494106bba moved strdupa from compat/misc to strings
\+ missing include guard
2024-06-12 14:26:34 +02:00
Martin Pulec
f01e4c36b7 moved around compat functions
moved compat functions from config_*h, namely:
- localtime_s/gmtime_s
- strerror_s
- mkdir Windows compat
- removed str[n]cmp from compat/misc (already in compat/strings,h,
which is the better location)

Do not use config*.h in export.c (motivation for the above changes).
2024-06-12 14:02:42 +02:00
Martin Pulec
44665ba19d export: added option exit_on_limit
In conjunction with "limit" useful for testing (namely to documentation
purposes, eg. on GH).
2024-06-12 13:33:29 +02:00
Martin Pulec
854c5543af CID 437903 fix
The strdup-ed pointer was actually not leaked but assigned to
s->dir. There was, anyways, just one poblem, when the dir started with
':', so. `strtok(cfg_copy, ":")` would skip leading ':' returning
cfg_copy+1. That would then be passed to free in export_destroy(), which
would most likely crash on invalid pointer.
2024-02-28 13:12:09 +01:00
Martin Pulec
10c389d62e export: small simplification 2024-02-19 13:05:47 +01:00
Martin Pulec
23f453f8f6 export: increase log level if creating subdir
Although not fatal, it is most likely not requested so use ERROR log
level.
2023-10-20 10:07:18 +02:00
Martin Pulec
199a67e98d export: small improvements
- simplified a bit
- create_anonymous_dir->create_implicit_dir (obviously, the name
_export.<date>_ is not much anonymous)
2023-08-15 09:05:56 +02:00
Martin Pulec
f0f7140e60 fixed Coverity ID 4165{59,60} 2023-08-15 08:25:49 +02:00
Martin Pulec
d035fcefdf platform_mkdir->mkdir: use POSIX syntax
Use rather defined function as mkdir(3p) is, even though there is needed
a compat for MSW.

+ removed some strtok_r undef, which should no longer be needed (see
also commit 6c6253c9)
2023-08-14 16:06:16 +02:00
Martin Pulec
eef553d9aa export create_anonymous_dir: small rewrite
removed non-thread safe functions + other small improvements
2023-08-10 08:01:36 +02:00
Martin Pulec
90a84dc88b fixed few warnings 2023-08-09 16:08:30 +02:00
Martin Pulec
ca9948449b shortopts for --record/--playback
It is '-E' and '-I' (Export and Import; R/P not viable because 'P' is
already taken for port so the shortcuts won't be consistent then).
2023-06-20 13:37:46 +02:00
Martin Piatka
276d14380a export: Fix sprintf warning 2022-08-31 14:02:34 +02:00
Martin Pulec
2e424d50ca replaced instances of color_out with color_printf
+ reindent vidcap/file help ("where" keyword)
2022-08-04 14:07:45 +02:00
Martin Pulec
46746286ec export.c: use color_printf for help 2022-07-27 09:05:55 +02:00
Martin Pulec
b48ce2af53 export.c: refactor a bit
+ accept help option also as other than first parameter
2022-02-24 11:56:06 +01:00
Martin Pulec
1b3b27eb7c Updated copyright dates for modified files 2021-11-08 15:43:14 +01:00
Martin Pulec
702dd4e798 Export: added noaudio/novideo option
+ small improvements (use of MAX_PATH_SIZE)
2021-10-06 16:45:01 +02:00
Martin Pulec
807183c155 Export: added "override" option 2021-09-30 15:13:59 +02:00
Martin Pulec
cdf6e8acc6 Export: option to limit number of output frames 2021-02-02 13:08:44 +01:00
Martin Pulec
54c1678b7a Export: fixed a typo 2020-07-09 13:34:03 +02:00
Martin Pulec
27edf9ad71 Fixes 2019-12-04 13:28:02 +01:00
Martin Pulec
09f6bafc58 Coverity fixes 2019-11-22 13:54:51 +01:00
Martin Pulec
cb9b649b60 Export: option to start paused with specified directory 2019-11-21 16:50:58 +01:00
Martin Pulec
72bf3d0e48 Export: added help 2019-11-21 16:50:57 +01:00
Martin Pulec
2d7e618c3a Export: allow non-empty directories 2019-11-21 16:50:55 +01:00
Martin Pulec
25b612031c Export: highlight output dir in output 2019-11-21 13:48:04 +01:00
Martin Pulec
4c71573a89 Fixed first series of Coverity bugs 2019-11-09 17:20:37 +01:00
Martin Pulec
31d9809fcd Updated documentation
Updated authors, copyright to 3-clause BSD (where possible) and file-level Doxygen
2019-11-09 13:47:11 +01:00
Ben Roeder
e4111c76b8 fixes for typos in messages 2018-09-11 12:51:21 +01:00
Martin Piatka
240d75b412 Export: Fix crash when exporter == NULL
This fixes reflector crashing when transcoding
2017-09-25 13:27:46 +02:00
Martin Pulec
a09a1d6454 Export: use more human readable dir names
Use directory names with date.
2017-09-20 16:18:24 +02:00
Martin Pulec
cf234ef3a8 Keyboard control: print whether we are exporting 2017-06-21 10:12:14 +02:00
Martin Pulec
e299219167 Export: allow runtime enable/disable recording 2017-05-11 13:53:26 +02:00
Martin Pulec
29fec0d9c9 Export: created umbrella for audio and video 2017-05-11 13:53:26 +02:00