Skip to content
Snippets Groups Projects

matrix: Transfer ownership of client to pointer array

Merged Guido Günther requested to merge agx/libcmatrix:client-cleanup into main
  1. Aug 04, 2024
    • Guido Gunther's avatar
      matrix: Transfer ownership of client to pointer array · 40505f20
      Guido Gunther authored and Guido Günther's avatar Guido Günther committed
      The pointer array uses a `g_object_unref()` as cleanup func so we need
      to add a ref'ed object to the array as `client` is marked as
      `g_autoptr`.
      
      This fixes a crash on shutdown in eignvalue when we unref the client we
      get from the liststore returned by `cm_matrix_get_clients_list()` via
      `g_list_model_get_item()` (which gives us a reference).
      40505f20