Blame SOURCES/0029-daemon-augeas-Don-t-test-if-AUG_NO_ERR_CLOSE-is-defi.patch
|
|
022f11 |
From 6beec59965fb3c18ad58d7541199a87d8d7fd4b5 Mon Sep 17 00:00:00 2001
|
|
|
022f11 |
From: "Richard W.M. Jones" <rjones@redhat.com>
|
|
|
022f11 |
Date: Mon, 2 Sep 2013 19:37:57 +0100
|
|
|
022f11 |
Subject: [PATCH] daemon: augeas: Don't test if AUG_NO_ERR_CLOSE is defined.
|
|
|
022f11 |
|
|
|
022f11 |
It's an enum, not a macro, and in any case it has been present in
|
|
|
022f11 |
augeas.h since 0.10.0, and the minimum version that libguestfs
|
|
|
022f11 |
requires is 1.0.0.
|
|
|
022f11 |
|
|
|
022f11 |
This fixes commit 3d132f29204e8c5c77f08841b5288dfe3013f4f0.
|
|
|
022f11 |
|
|
|
022f11 |
(cherry picked from commit 091eb0780349dade778d1ad3412ffacc7ffec9ec)
|
|
|
022f11 |
---
|
|
|
022f11 |
daemon/augeas.c | 6 ------
|
|
|
022f11 |
1 file changed, 6 deletions(-)
|
|
|
022f11 |
|
|
|
022f11 |
diff --git a/daemon/augeas.c b/daemon/augeas.c
|
|
|
022f11 |
index 9d6a553..45338da 100644
|
|
|
022f11 |
--- a/daemon/augeas.c
|
|
|
022f11 |
+++ b/daemon/augeas.c
|
|
|
022f11 |
@@ -98,26 +98,20 @@ do_aug_init (const char *root, int flags)
|
|
|
022f11 |
return -1;
|
|
|
022f11 |
}
|
|
|
022f11 |
|
|
|
022f11 |
-#ifdef AUG_NO_ERR_CLOSE
|
|
|
022f11 |
/* Pass AUG_NO_ERR_CLOSE so we can display detailed errors. */
|
|
|
022f11 |
aug = aug_init (buf, NULL, flags | AUG_NO_ERR_CLOSE);
|
|
|
022f11 |
-#else
|
|
|
022f11 |
- aug = aug_init (buf, NULL, flags);
|
|
|
022f11 |
-#endif
|
|
|
022f11 |
|
|
|
022f11 |
if (!aug) {
|
|
|
022f11 |
reply_with_error ("augeas initialization failed");
|
|
|
022f11 |
return -1;
|
|
|
022f11 |
}
|
|
|
022f11 |
|
|
|
022f11 |
-#ifdef AUG_NO_ERR_CLOSE
|
|
|
022f11 |
if (aug_error (aug) != AUG_NOERROR) {
|
|
|
022f11 |
AUGEAS_ERROR ("aug_init: %s (flags %d)", root, flags);
|
|
|
022f11 |
aug_close (aug);
|
|
|
022f11 |
aug = NULL;
|
|
|
022f11 |
return -1;
|
|
|
022f11 |
}
|
|
|
022f11 |
-#endif
|
|
|
022f11 |
|
|
|
022f11 |
return 0;
|
|
|
022f11 |
}
|
|
|
022f11 |
--
|
|
|
022f11 |
1.8.3.1
|
|
|
022f11 |
|