[vlc-commits] test: fix test_media_subitems without HAVE_OPENAT
Thomas Guillem
git at videolan.org
Fri Nov 6 11:31:50 CET 2015
vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Fri Nov 6 11:30:42 2015 +0100| [24f1ec9c1c290dc3e2a18c63b400c068c7800cfe] | committer: Thomas Guillem
test: fix test_media_subitems without HAVE_OPENAT
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=24f1ec9c1c290dc3e2a18c63b400c068c7800cfe
---
test/libvlc/media.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/test/libvlc/media.c b/test/libvlc/media.c
index e6201c5..0070e7b 100644
--- a/test/libvlc/media.c
+++ b/test/libvlc/media.c
@@ -198,6 +198,8 @@ static void test_media_subitems(const char** argv, int argc)
}
free (subitems_realpath);
+#ifdef HAVE_OPENAT
+ /* listing directory via a fd works only if HAVE_OPENAT is defined */
int fd = open (subitems_path, O_RDONLY);
log ("Testing media_subitems: fd: '%d'\n", fd);
assert (fd >= 0);
@@ -206,7 +208,9 @@ static void test_media_subitems(const char** argv, int argc)
test_media_subitems_media (media, true);
libvlc_media_release (media);
close (fd);
-
+#else
+#warning not testing subitems list via a fd location
+#endif
libvlc_release (vlc);
}
More information about the vlc-commits
mailing list