about summary refs log tree commit diff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2006-01-16 20:14:50 +0000
committerUlrich Drepper <drepper@redhat.com>2006-01-16 20:14:50 +0000
commit63f8fe54565b20dc7adb23381a7eb21439f02a40 (patch)
treea5e8b8558680be271be24ae8fce6d067c921261b
parent2d79a585c11cdd89f6406c49f339bac3def51431 (diff)
downloadglibc-63f8fe54565b20dc7adb23381a7eb21439f02a40.tar.gz
glibc-63f8fe54565b20dc7adb23381a7eb21439f02a40.tar.xz
glibc-63f8fe54565b20dc7adb23381a7eb21439f02a40.zip
* libio/stdio.h: Declare open_wmemstream.
	* libio/Versions: Export open_wmemstream for GLIBC_2.4.
-rw-r--r--ChangeLog2
-rw-r--r--libio/Makefile6
-rw-r--r--libio/Versions3
-rw-r--r--libio/stdio.h5
4 files changed, 14 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index d147d69184..94ce153853 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -775,6 +775,8 @@
 2006-01-11  Ulrich Drepper  <drepper@redhat.com>
 
 	* libio/wmemstream.c: New file.
+	* libio/stdio.h: Declare open_wmemstream.
+	* libio/Versions: Export open_wmemstream for GLIBC_2.4.
 	* libio/Makefile (routines): Add wmemstream.
 	(tests): Add tst-memstream1, tst-memstream2, tst-wmemstream2, and
 	tst-wmemstream2.
diff --git a/libio/Makefile b/libio/Makefile
index 5817bd7532..4437872984 100644
--- a/libio/Makefile
+++ b/libio/Makefile
@@ -35,7 +35,7 @@ routines	:=							      \
 	iofputws iofputws_u iogetwline iowpadn ioungetwc putwc putwc_u	      \
 	putwchar putwchar_u putchar putchar_u fwprintf swprintf vwprintf      \
 	wprintf wscanf fwscanf vwscanf vswprintf iovswscanf swscanf wgenops   \
-	wstrops wfileops iofwide fwide					      \
+	wstrops wfileops iofwide fwide wmemstream			      \
 									      \
 	clearerr feof ferror fileno fputc freopen fseek getc getchar	      \
 	memstream pclose putc putchar rewind setbuf setlinebuf vasprintf      \
@@ -54,7 +54,9 @@ tests = tst_swprintf tst_wprintf tst_swscanf tst_wscanf tst_getwc tst_putwc   \
 	tst-freopen bug-rewind bug-rewind2 bug-ungetc bug-fseek \
 	tst-mmap-eofsync tst-mmap-fflushsync bug-mmap-fflush \
 	tst-mmap2-eofsync tst-mmap-offend bug-fopena+ bug-wfflush \
-	bug-ungetc2 bug-ftell bug-ungetc3 bug-ungetc4
+	bug-ungetc2 bug-ftell bug-ungetc3 bug-ungetc4 \
+	tst-memstream1 tst-memstream2 \
+	tst-wmemstream1 tst-wmemstream2
 test-srcs = test-freopen
 
 all: # Make this the default target; it will be defined in Rules.
diff --git a/libio/Versions b/libio/Versions
index c870494872..e7a96daca5 100644
--- a/libio/Versions
+++ b/libio/Versions
@@ -145,6 +145,9 @@ libc {
     # w*
     wprintf; wscanf;
   }
+  GLIBC_2.4 {
+    open_wmemstream;
+  }
   GLIBC_PRIVATE {
     # Used by NPTL and librt
     __libc_fatal;
diff --git a/libio/stdio.h b/libio/stdio.h
index fbe0f568a0..566ec5a9bf 100644
--- a/libio/stdio.h
+++ b/libio/stdio.h
@@ -293,6 +293,11 @@ extern FILE *fmemopen (void *__s, size_t __len, __const char *__modes) __THROW;
    and the number of characters written on fflush or fclose.  */
 extern FILE *open_memstream (char **__restrict __bufloc,
 			     size_t *__restrict __sizeloc) __THROW;
+
+/* Like OPEN_MEMSTREAM, but the stream is wide oriented and produces
+   a wide character string.  */
+extern FILE *open_wmemstream (wchar_t **__restrict __bufloc,
+			      size_t *__restrict __sizeloc) __THROW;
 #endif