Revert "tests: Avoid gnulib replacements in mocks"

Now that we're no longer using gnulib, we can treat macOS the
same as all other targets.

This reverts commit 0ae6f5cea5

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Roman Bolshakov <r.bolshakov@yadro.com>
Tested-by: Roman Bolshakov <r.bolshakov@yadro.com>
This commit is contained in:
Andrea Bolognani 2021-02-04 11:05:48 +01:00
parent b29c86ae10
commit ab4834a786
2 changed files with 0 additions and 15 deletions

View File

@ -163,12 +163,7 @@ int access(const char *path, int mode)
return real_access(newpath ? newpath : path, mode);
}
# ifdef __APPLE__
int _open(const char *path, int flags, ...) __asm("_open");
int _open(const char *path, int flags, ...)
# else
int open(const char *path, int flags, ...)
# endif
{
g_autofree char *newpath = NULL;
va_list ap;

View File

@ -215,12 +215,7 @@ static int virMockStatRedirect(const char *path, char **newpath);
#endif
#ifdef MOCK_STAT
# ifdef __APPLE__
int _stat(const char *path, struct stat *sb) __asm("_stat$INODE64");
int _stat(const char *path, struct stat *sb)
# else
int stat(const char *path, struct stat *sb)
# endif
{
g_autofree char *newpath = NULL;
@ -290,13 +285,8 @@ __xstat64(int ver, const char *path, struct stat64 *sb)
#endif
#ifdef MOCK_LSTAT
# ifdef __APPLE__
int _lstat(const char *path, struct stat *sb) __asm("_lstat$INODE64");
int _lstat(const char *path, struct stat *sb)
# else
int
lstat(const char *path, struct stat *sb)
# endif
{
g_autofree char *newpath = NULL;