The virFileWrapperClearPrefixes() function is defined only when
building for non-WIN32.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
Technically a build breaker fix, but I can't decide if ifdef is better
or removing the call is better.
tests/domaincapstest.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/domaincapstest.c b/tests/domaincapstest.c
index 3ee95a4b58..92676bdd6e 100644
--- a/tests/domaincapstest.c
+++ b/tests/domaincapstest.c
@@ -476,7 +476,9 @@ mymain(void)
DO_TEST_BHYVE("fbuf", "/usr/sbin/bhyve", &bhyve_caps, VIR_DOMAIN_VIRT_BHYVE);
#endif /* WITH_BHYVE */
+#ifndef WIN32
virFileWrapperClearPrefixes();
+#endif /* WIN32 */
return ret;
}
--
2.21.0
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
On Wed, Apr 10, 2019 at 03:12:18PM +0200, Michal Privoznik wrote: > The virFileWrapperClearPrefixes() function is defined only when > building for non-WIN32. > > Signed-off-by: Michal Privoznik <mprivozn@redhat.com> > --- > > Technically a build breaker fix, but I can't decide if ifdef is better > or removing the call is better. I don't much care since it only affects one place, but personally I would have just make a no-op virFileWrapperClearPrefixes() impl that is built on Win32. > > tests/domaincapstest.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/tests/domaincapstest.c b/tests/domaincapstest.c > index 3ee95a4b58..92676bdd6e 100644 > --- a/tests/domaincapstest.c > +++ b/tests/domaincapstest.c > @@ -476,7 +476,9 @@ mymain(void) > DO_TEST_BHYVE("fbuf", "/usr/sbin/bhyve", &bhyve_caps, VIR_DOMAIN_VIRT_BHYVE); > #endif /* WITH_BHYVE */ > > +#ifndef WIN32 > virFileWrapperClearPrefixes(); > +#endif /* WIN32 */ > > return ret; Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :| -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
On Thu, 2019-04-11 at 12:33 +0100, Daniel P. Berrangé wrote: > On Wed, Apr 10, 2019 at 03:12:18PM +0200, Michal Privoznik wrote: > > The virFileWrapperClearPrefixes() function is defined only when > > building for non-WIN32. > > > > Signed-off-by: Michal Privoznik <mprivozn@redhat.com> > > --- > > > > Technically a build breaker fix, but I can't decide if ifdef is better > > or removing the call is better. > > I don't much care since it only affects one place, but personally > I would have just make a no-op virFileWrapperClearPrefixes() impl > that is built on Win32. We ended up using a different approach after all (947ea8665e4e). Stubbing out ClearPrefixes() on win32 would only paper over the issue; on the other hand, I'm pretty sure simply stubbing out all virFileWrapper APIs would not fly because we *need* to wrap file access for the tests using the API to work properly. -- Andrea Bolognani / Red Hat / Virtualization -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
© 2016 - 2024 Red Hat, Inc.