From ac119ae83bf6d1a1fd5f8aa609180dacf220a3e8 Mon Sep 17 00:00:00 2001 From: DJ Delorie Date: Mon, 11 Apr 2005 19:32:04 +0000 Subject: merge from gcc --- include/ChangeLog | 5 +++++ include/libiberty.h | 8 ++++++++ 2 files changed, 13 insertions(+) (limited to 'include') diff --git a/include/ChangeLog b/include/ChangeLog index 9881787..796a4ab 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,8 @@ +2005-04-11 Kaveh R. Ghazi + + * libiberty.h (fopen_unlocked, fdopen_unlocked, freopen_unlocked): + Provide prototypes for new functions. + 2005-03-29 Ian Lance Taylor * libiberty.h: Fix indentation. diff --git a/include/libiberty.h b/include/libiberty.h index eb5633b..80aee8b 100644 --- a/include/libiberty.h +++ b/include/libiberty.h @@ -48,6 +48,14 @@ extern "C" { #include +/* Open and return a FILE pointer. If the OS supports it, ensure that + the stream is setup to avoid any multi-threaded locking. Otherwise + return the FILE pointer unchanged. */ + +extern FILE *fopen_unlocked (const char *path, const char *mode); +extern FILE *fdopen_unlocked (int fildes, const char *mode); +extern FILE *freopen_unlocked (const char *path, const char *mode, FILE *stream); + /* Build an argument vector from a string. Allocates memory using malloc. Use freeargv to free the vector. */ -- cgit v1.1