about summary refs log tree commit diff
path: root/stdio-common
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2022-12-19 18:56:55 +0100
committerFlorian Weimer <fweimer@redhat.com>2022-12-19 18:56:55 +0100
commit5365acc567a49270b4341b9d325794ec554258d9 (patch)
tree97ae39cd514942f00ab030282b1732ba5b72b30a /stdio-common
parent8ece45e4f586abd212d1c02d74d38ef681a45600 (diff)
downloadglibc-5365acc567a49270b4341b9d325794ec554258d9.tar.gz
glibc-5365acc567a49270b4341b9d325794ec554258d9.tar.xz
glibc-5365acc567a49270b4341b9d325794ec554258d9.zip
libio: Convert __obstack_vprintf_internal to buffers (bug 27124)
This fixes bug 27124 because the problematic built-in vtable is gone.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
Diffstat (limited to 'stdio-common')
-rw-r--r--stdio-common/printf_buffer_flush.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/stdio-common/printf_buffer_flush.c b/stdio-common/printf_buffer_flush.c
index 922340cc54..42afe49413 100644
--- a/stdio-common/printf_buffer_flush.c
+++ b/stdio-common/printf_buffer_flush.c
@@ -32,6 +32,7 @@
 # pragma weak __printf_buffer_flush_fp
 # pragma weak __printf_buffer_flush_fp_to_wide
 # pragma weak __printf_buffer_flush_fphex_to_wide
+# pragma weak __printf_buffer_flush_obstack
 #endif /* !SHARED */
 
 static void
@@ -72,6 +73,9 @@ __printf_buffer_do_flush (struct __printf_buffer *buf)
       __printf_buffer_flush_fphex_to_wide
         ((struct __printf_buffer_fphex_to_wide *) buf);
       return;
+    case __printf_buffer_mode_obstack:
+      __printf_buffer_flush_obstack ((struct __printf_buffer_obstack *) buf);
+      return;
     }
   __builtin_trap ();
 }