Skip to contentSkip to conversation

guest-agent: only enable FSFREEZE when it's supported by the kernel

PATCH New Anthony Liguori 1 participant 1 message Jul 23, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 guest-agent: only enable FSFREEZE when it's supported by the kernel

---
 qga/guest-agent-commands.c |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
qga/guest-agent-commands.c +7 -5
index 624972e..30c4068 100644
@@ -10,15 +10,17 @@
  * See the COPYING file in the top-level directory.
  */
 
-#if defined(__linux__)
-#define CONFIG_FSFREEZE
-#endif
-
 #include <glib.h>
-#if defined(CONFIG_FSFREEZE)
+
+#if defined(__linux__)
 #include <mntent.h>
 #include <linux/fs.h>
+
+#if defined(__linux__) && defined(FIFREEZE)
+#define CONFIG_FSFREEZE
 #endif
+#endif
+
 #include <sys/types.h>
 #include <sys/ioctl.h>
 #include "qga/guest-agent-core.h"
Signature · 1 line
1.7.4.1