summaryrefslogtreecommitdiffstats
path: root/libc/stdio/findfp.c
diff options
context:
space:
mode:
authorDavid 'Digit' Turner <digit@google.com>2011-11-16 07:31:31 -0800
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-11-16 07:31:31 -0800
commitb38522983712432ba143c046343ba4fa01baf7c8 (patch)
treedda761ca6d2ea14ee7f181fb89625fc4c97e1f28 /libc/stdio/findfp.c
parent90c4c1e82b946c838f22be9c0bb3dcf81eaf26ca (diff)
parent9831ad3ce6bd5b22da16a275ed67e7236eae3d1f (diff)
downloadbionic-b38522983712432ba143c046343ba4fa01baf7c8.zip
bionic-b38522983712432ba143c046343ba4fa01baf7c8.tar.gz
bionic-b38522983712432ba143c046343ba4fa01baf7c8.tar.bz2
Merge "libc: speed-up flockfile()/funlockfile()"
Diffstat (limited to 'libc/stdio/findfp.c')
-rw-r--r--libc/stdio/findfp.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/libc/stdio/findfp.c b/libc/stdio/findfp.c
index a659c87..76ed5ee 100644
--- a/libc/stdio/findfp.c
+++ b/libc/stdio/findfp.c
@@ -58,7 +58,12 @@ static struct glue uglue = { 0, FOPEN_MAX - 3, usual };
static struct glue *lastglue = &uglue;
_THREAD_PRIVATE_MUTEX(__sfp_mutex);
-static struct __sfileext __sFext[3];
+static struct __sfileext __sFext[3] = {
+ _FILEEXT_INITIALIZER,
+ _FILEEXT_INITIALIZER,
+ _FILEEXT_INITIALIZER,
+};
+
FILE __sF[3] = {
std(__SRD, STDIN_FILENO), /* stdin */
std(__SWR, STDOUT_FILENO), /* stdout */