lib: Add OSTREE_SUPPRESS_SYNCFS environment variable
Just to work around valgrind not understanding the `syncfs()` syscall in EL7 right now. Closes: #292 Approved by: krnowak
This commit is contained in:
parent
0f7bf7be95
commit
c015fe13fb
|
|
@ -1469,10 +1469,16 @@ ostree_repo_commit_transaction (OstreeRepo *self,
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (syncfs (self->tmp_dir_fd) < 0)
|
/* FIXME: Added since valgrind in el7 doesn't know about
|
||||||
|
* `syncfs`...we should delete this later.
|
||||||
|
*/
|
||||||
|
if (g_getenv ("OSTREE_SUPRESS_SYNCFS") == NULL)
|
||||||
{
|
{
|
||||||
glnx_set_error_from_errno (error);
|
if (syncfs (self->tmp_dir_fd) < 0)
|
||||||
goto out;
|
{
|
||||||
|
glnx_set_error_from_errno (error);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!rename_pending_loose_objects (self, cancellable, error))
|
if (!rename_pending_loose_objects (self, cancellable, error))
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue