mailing list of musl libc
 help / color / mirror / code / Atom feed
2a38c8d0bd146943ce61f9c500c8d110bf2d83df blob 508 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 
#include "stdio_impl.h"

WEAK_PROVIDE_DUMMY;
_Readonly_alias FILE *const __stdin_used;
_Readonly_alias FILE *const __stdout_used;
_Readonly_alias FILE *const __stderr_used;

static void close_file(FILE *f)
{
	if (!f) return;
	FFINALLOCK(f);
	if (f->wpos > f->wbase) f->write(f, 0, 0);
	if (f->rpos < f->rend) f->seek(f, f->rpos-f->rend, SEEK_CUR);
}

void __stdio_exit(void)
{
	FILE *f;
	OFLLOCK();
	for (f=libc.ofl_head; f; f=f->next) close_file(f);
	close_file(__stdin_used);
	close_file(__stdout_used);
}
debug log:

solving 2a38c8d ...
found 2a38c8d in https://inbox.vuxu.org/musl/cec5070e43b6a06a77908c926d8822ed58baa458.1360968989.git.Jens.Gustedt@inria.fr/
found 0fb3323 in https://git.vuxu.org/mirror/musl/
preparing index
index prepared:
100644 0fb3323489301651c14b0f516b94fb8f7b7bb3cf	src/stdio/__stdio_exit.c

applying [1/1] https://inbox.vuxu.org/musl/cec5070e43b6a06a77908c926d8822ed58baa458.1360968989.git.Jens.Gustedt@inria.fr/
diff --git a/src/stdio/__stdio_exit.c b/src/stdio/__stdio_exit.c
index 0fb3323..2a38c8d 100644

Checking patch src/stdio/__stdio_exit.c...
Applied patch src/stdio/__stdio_exit.c cleanly.

index at:
100644 2a38c8d0bd146943ce61f9c500c8d110bf2d83df	src/stdio/__stdio_exit.c

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).