Merge pull request #1947 from cgwalters/more-scan-build-2
More scan build 2
This commit is contained in:
6 files changed
+22
-37
No files matched your search
@@ -1588,7 +1588,6 @@ ostree_repo_prepare_transaction (OstreeRepo *self,
|
||||
GCancellable *cancellable,
|
||||
GError **error)
|
||||
{
|
||||
g_autoptr(_OstreeRepoAutoTransaction) txn = NULL;
|
||||
guint64 reserved_bytes = 0;
|
||||
|
||||
g_return_val_if_fail (self->in_transaction == FALSE, FALSE);
|
||||
@@ -1596,7 +1595,8 @@ ostree_repo_prepare_transaction (OstreeRepo *self,
|
||||
g_debug ("Preparing transaction in repository %p", self);
|
||||
|
||||
/* Set up to abort the transaction if we return early from this function. */
|
||||
txn = self;
|
||||
g_autoptr(_OstreeRepoAutoTransaction) txn = self;
|
||||
(void) txn; /* Add use to silence static analysis */
|
||||
|
||||
memset (&self->txn.stats, 0, sizeof (OstreeRepoTransactionStats));
|
||||
|
||||
@@ -1652,7 +1652,7 @@ ostree_repo_prepare_transaction (OstreeRepo *self,
|
||||
return FALSE;
|
||||
|
||||
/* Success: do not abort the transaction when returning. */
|
||||
txn = NULL;
|
||||
txn = NULL; (void) txn;
|
||||
|
||||
if (out_transaction_resume)
|
||||
*out_transaction_resume = ret_transaction_resume;
|
||||
|
||||
@@ -2181,7 +2181,6 @@ static void
|
||||
start_fetch (OtPullData *pull_data,
|
||||
FetchObjectData *fetch)
|
||||
{
|
||||
gboolean is_meta;
|
||||
g_autofree char *obj_subpath = NULL;
|
||||
guint64 *expected_max_size_p;
|
||||
guint64 expected_max_size;
|
||||
@@ -2190,13 +2189,12 @@ start_fetch (OtPullData *pull_data,
|
||||
GPtrArray *mirrorlist = NULL;
|
||||
|
||||
ostree_object_name_deserialize (fetch->object, &expected_checksum, &objtype);
|
||||
is_meta = OSTREE_OBJECT_TYPE_IS_META (objtype);
|
||||
|
||||
g_debug ("starting fetch of %s.%s%s", expected_checksum,
|
||||
ostree_object_type_to_string (objtype),
|
||||
fetch->is_detached_meta ? " (detached)" : "");
|
||||
|
||||
is_meta = OSTREE_OBJECT_TYPE_IS_META (objtype);
|
||||
gboolean is_meta = OSTREE_OBJECT_TYPE_IS_META (objtype);
|
||||
if (is_meta)
|
||||
pull_data->n_outstanding_metadata_fetches++;
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user