Instead of passing a ActionRef to the execute function of validate
action types, pass a borrowed Action. This is required for ASYNC actions
as you need to pass the one action structure around so it can be
`set_done` when the async action is done.
This implies that the action structure won't be mutable anymore, but
using the fact that it is "mutable" in C is not clean and in rust we can
just capture variables to achieve similar results anyway.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1265>
[helix] can use project specific configuration in the `.helix` directory under
the project root. For gst-rs development, this can be used to select a group of
features:
.helix/languages.toml:
```toml
[language-server.rust-analyzer.config]
cargo = { features = ["v1_26"] }
```
It can also be used to configure debugging targets, thought debugging experience
with helix is lacking currently.
[helix]: https://helix-editor.com/
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1554>
GStreamer fixes a memory leak due to GQuarks by switching to GstIdStr.
The consequence is that strings previously backed by a GQuark returned by a
function will now get their lifetime bound to that of its owner, while the
GQuark version ensured static lifetime.
Because some functions return a string with the assumption that they are static
and because we can't alter the API for existing versions of the bindings, this
MR temporarily forces affected strings as GQuarks, thus gaining static lifetime
regardless of the GStreamer version actually being used.
For newer versions of the bindings, the API will be fixed and GQuarks will be
removed in favor a leakless solution.
See: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7432
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1519>
The signature for `TagListRef::index` didn't bind the lifetime of the returned
`TagValue` to `&self`. This causes the following code to compile:
```rust
1 let title = {
2 let mut tags = TagList::new();
3 {
4 let tags = tags.get_mut().unwrap();
5 tags.add::<Title>(&"some title", TagMergeMode::Append);
6 }
7
8 let title = tags.index::<Title>(0).unwrap();
9 assert_eq!(title.get(), "some title");
10
11 title
12 };
13
14 assert_eq!(title.get(), "some title");
```
... but it panics at runtime on the last `title.get()`:
```
Invalid tag type: WrongValueType(ValueTypeMismatchError
{ actual: <invalid>, requested: gchararray })
```
Indeed, the `title` `TagValue` is freed with the `tags` on line 12.
This commit fixes the function signature so the returned `TagValue` can't
outlive its `TagListRef`.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1518>
Seems like the placeholder runner is having issues with git-lfs atm.
```
Could not pull
Errors logged to '/builds/alatiera/gstreamer-rs/.git/modules/gir-files/lfs/logs/20240820T212811.645856902.log'.
Use `git lfs logs last` to view the log.
fatal: run_command returned non-zero status for gir-files
```
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1503>
GTK 4.14 needs a newer glib, but we cannot build and use our own
because the system glib ends up taking precedence because cargo-c
doesn't set RPATHs for the plugins it builds.
The oldest GTK that supports glib 2.74 is GTK 4.10, and Debian 12
ships GTK 4.8, so let's just use the system GTK.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1500>