repo: Make abort_transaction silently succeed if we're not in a transaction
This helps callers out a lot, and means we can always call abort_transaction at the end of a function. https://bugzilla.gnome.org/show_bug.cgi?id=707644
This commit is contained in:
1 parent
ef61724269
commit
f84504a8c4
2 files changed
+4
-15
No files matched your search
@@ -662,6 +662,9 @@ ostree_repo_abort_transaction (OstreeRepo *self,
|
||||
{
|
||||
gboolean ret = FALSE;
|
||||
|
||||
if (!self->in_transaction)
|
||||
return TRUE;
|
||||
|
||||
if (!cleanup_tmpdir (self, cancellable, error))
|
||||
goto out;
|
||||
|
||||
|
||||
Reference in new issue
Block a user