]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
virmocklibxl.c: Fix include of virfile.h
authorMichal Privoznik <mprivozn@redhat.com>
Wed, 18 Apr 2018 07:37:09 +0000 (09:37 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Wed, 18 Apr 2018 07:59:52 +0000 (09:59 +0200)
Firstly, this isn't supposed to be in angle brackets because it's
not a system header file (not that gcc distinguishes these two,
it's just guide for us developers).

Secondly, no need to use util/ path prefix because CFLAGS already
contain -I$(srcdir)/util.

The include is needed because virmocklibxl is mocking
virFileMakePath() and even when VIR_MOCK_IMPL_RET_ARGS() does
forward declaration to shut up compiler we need real
virFileMakePath() declaration so that when it changes compiler
catches mismatching declarations.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
tests/virmocklibxl.c

index 50ae25810f457e1f610553dfd0439df054aaf107..546c6d6a43865640238f9fbad9c725aeba365599 100644 (file)
 # include <sys/stat.h>
 # include <unistd.h>
 # include <libxl.h>
-# include <util/virfile.h>
 # include <xenstore.h>
 # include <xenctrl.h>
 # include <sys/socket.h>
 
+# include "virfile.h"
+
 VIR_MOCK_IMPL_RET_VOID(xs_daemon_open,
                        struct xs_handle *)
 {