Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GVariant, GError and g_autoptr cleanups #1439

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Commits on Oct 4, 2024

  1. Configuration menu
    Copy the full SHA
    7bc435a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ac5f7d8 View commit details
    Browse the repository at this point in the history
  3. Always create an empty vardict instead of passing NULL

    In the error case, we will clear the GVariant and then try to emit a
    response from a NULL pointer as result. Always create an empty vardict
    when something failed instead.
    
    This also clears the error because we continue on in the error case and
    do in fact re-using it in one case.
    swick committed Oct 4, 2024
    Configuration menu
    Copy the full SHA
    2c9a981 View commit details
    Browse the repository at this point in the history
  4. portals: Work with owned, non-floating GVariants where possible

    By g_variant_ref_sink'ing floating GVariants as early as possible. This
    fixes a few cases where the variant would be leaked, where the floating
    ref would be owned by a g_autoptr and makes it easier to see who owns
    the reference.
    
    Cases where the floating ref is passed into a function which immediately
    sinks the floating ref are left untouched.
    swick committed Oct 4, 2024
    Configuration menu
    Copy the full SHA
    543178d View commit details
    Browse the repository at this point in the history