build: provide replacement for TEMP_FAILURE_RETRY if not present

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
Giuseppe Scrivano 2019-03-07 10:22:26 +01:00
parent 57b1e98d69
commit f17f15a48b
No known key found for this signature in database
GPG Key ID: E4730F97F60286ED

10
main.c
View File

@ -73,6 +73,16 @@
#include <utils.h>
#ifndef TEMP_FAILURE_RETRY
#define TEMP_FAILURE_RETRY(expression) \
(__extension__ \
({ long int __result; \
do __result = (long int) (expression); \
while (__result == -1L && errno == EINTR); \
__result; }))
#endif
#ifndef HAVE_OPEN_BY_HANDLE_AT
struct file_handle
{