Skip to content
  • Niels De Graef's avatar
    secret-tool: Fix memory issues in lock command · a1ceaeed
    Niels De Graef authored
    There were several issues in `secret_tool_action_lock()`:
    
    - `g_autolist (GList)` isn't a correct type, as the list elements are
      `SecretCollection`s, not `GList`s
    - Separately from that, the list didn't take ownership of the elements
      either in all cases
    - We were leaking the `locked` and `context` variables
    
    This commits just does away with all the g_auto* usage as it's the only
    place in the code we're using it anyway, and just does all the freeing
    at the end of the function.
    
    Fixes: 015ea119 ("secret-tool: Add locking capabilities to secret tool")
    Fixes: #89
    a1ceaeed