From: Ian Jackson Date: Tue, 15 Jul 2008 16:45:26 +0000 (+0100) Subject: ioemu-remote: Fix the pass-through compilation. X-Git-Tag: xen-3.3.0-rc1~33 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=b7eec990223bb8c4b145597af37592103c412542;p=qemu-xen-4.0-testing.git ioemu-remote: Fix the pass-through compilation. Signed-off-by: Jean Guyader --- diff --git a/hw/pass-through.c b/hw/pass-through.c index bddc203f..1bd8d66d 100644 --- a/hw/pass-through.c +++ b/hw/pass-through.c @@ -713,7 +713,7 @@ int pt_init(PCIBus *e_bus, char *direct_pci) dpci_infos.pci_access = pci_access; dpci_infos.e_bus = e_bus; - if ( strlen(direct_pci) == 0 ) { + if ( !direct_pci || strlen(direct_pci) == 0 ) { return 0; } diff --git a/hw/pass-through.h b/hw/pass-through.h index ffd87ef9..d642be37 100644 --- a/hw/pass-through.h +++ b/hw/pass-through.h @@ -27,7 +27,7 @@ #define PT_LOGGING_ENABLED #ifdef PT_LOGGING_ENABLED -#define PT_LOG(_f, _a...) fprintf(logfile, "%s: " _f, __func__, ##_a) +#define PT_LOG(_f, _a...) fprintf(stdout, "%s: " _f, __func__, ##_a) #else #define PT_LOG(_f, _a...) #endif