[Spice-devel] [PATCH 4/8] display/driver: DebugPrint: check for log_level being set (allow using DebugPrint with pdev early)
Alon Levy
alevy at redhat.com
Mon Jun 20 03:50:52 PDT 2011
---
display/driver.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/display/driver.c b/display/driver.c
index 182343d..9a4ccd3 100644
--- a/display/driver.c
+++ b/display/driver.c
@@ -123,7 +123,7 @@ void DebugPrint(PDev *pdev, int level, const char *message, ...)
{
va_list ap;
- if (level > (pdev ? (int)*pdev->log_level : DBG_LEVEL)) {
+ if (level > (pdev && pdev->log_level ? (int)*pdev->log_level : DBG_LEVEL)) {
return;
}
va_start(ap, message);
--
1.7.5.2
More information about the Spice-devel
mailing list