aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/lvm/2.03.22/lvm2-013-fix-stdio-usage.patch')
-rw-r--r--patches/lvm/2.03.22/lvm2-013-fix-stdio-usage.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/patches/lvm/2.03.22/lvm2-013-fix-stdio-usage.patch b/patches/lvm/2.03.22/lvm2-013-fix-stdio-usage.patch
new file mode 100644
index 00000000..8f3835ec
--- /dev/null
+++ b/patches/lvm/2.03.22/lvm2-013-fix-stdio-usage.patch
@@ -0,0 +1,22 @@
+diff --git a/lib/commands/toolcontext.c b/lib/commands/toolcontext.c
+index 2256352..0408808 100644
+--- a/lib/commands/toolcontext.c
++++ b/lib/commands/toolcontext.c
+@@ -1667,7 +1667,7 @@ struct cmd_context *create_toolcontext(unsigned is_clvmd,
+ /* FIXME Make this configurable? */
+ reset_lvm_errno(1);
+
+-#ifndef VALGRIND_POOL
++#if !defined(VALGRIND_POOL) && defined(__GLIBC__)
+ /* Set in/out stream buffering before glibc */
+ if (set_buffering
+ #ifdef SYS_gettid
+@@ -2043,7 +2043,7 @@ void destroy_toolcontext(struct cmd_context *cmd)
+ dm_hash_destroy(cmd->cft_def_hash);
+
+ dm_device_list_destroy(&cmd->cache_dm_devs);
+-#ifndef VALGRIND_POOL
++#if !defined(VALGRIND_POOL) && defined(__GLIBC__)
+ if (cmd->linebuffer) {
+ /* Reset stream buffering to defaults */
+ if (is_valid_fd(STDIN_FILENO) &&