summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2021-08-18 09:10:17 -0400
committerGitHub <noreply@github.com>2021-08-18 09:10:17 -0400
commitcac4f2133b4f4d14c59c0fe4a2e568d0d938eac4 (patch)
tree8e5f4ca4ef07472e6a7086afa7da2f59ef225798
parent6cd585774f742bea9a1a6b681556750d2db7cc02 (diff)
parentb079c11381aa2b297652753d346b12b8112ef542 (diff)
downloadostree-cac4f2133b4f4d14c59c0fe4a2e568d0d938eac4.tar.gz
Merge pull request #2414 from lucab/ups/cli-commit-modifier-autoptr
builtins/commit: move commit modifier to auto-cleanup
-rw-r--r--src/ostree/ot-builtin-commit.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/ostree/ot-builtin-commit.c b/src/ostree/ot-builtin-commit.c
index 5aecdbdb..3698a2f4 100644
--- a/src/ostree/ot-builtin-commit.c
+++ b/src/ostree/ot-builtin-commit.c
@@ -432,7 +432,7 @@ ostree_builtin_commit (int argc, char **argv, OstreeCommandInvocation *invocatio
g_autoptr(GHashTable) skip_list = NULL;
OstreeRepoCommitModifierFlags flags = 0;
g_autoptr(OstreeSePolicy) policy = NULL;
- OstreeRepoCommitModifier *modifier = NULL;
+ g_autoptr(OstreeRepoCommitModifier) modifier = NULL;
OstreeRepoTransactionStats stats;
struct CommitFilterData filter_data = { 0, };
g_autofree char *commit_body = NULL;
@@ -980,7 +980,5 @@ ostree_builtin_commit (int argc, char **argv, OstreeCommandInvocation *invocatio
out:
if (repo)
ostree_repo_abort_transaction (repo, cancellable, NULL);
- if (modifier)
- ostree_repo_commit_modifier_unref (modifier);
return ret;
}