fileno.c\stdio\src - musl - musl - an implementation of the standard library for Linux-based systems

index : musl
musl - an implementation of the standard library for Linux-based systems
summary refs log tree commit diff
path: root/src/stdio/fileno.c
blob: ba7f9391b1ec9baa6023f9a66f569b46a1f85ba2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include "stdio_impl.h"
int fileno(FILE *f)
{
	/* f->fd never changes, but the lock must be obtained and released
	 * anyway since this function cannot return while another thread
	 * holds the lock. */
	FLOCK(f);
	FUNLOCK(f);
	return f->fd;
}
weak_alias(fileno, fileno_unlocked);
generated by cgit v1.2.1 (git 2.18.0) at 2025年09月27日 16:56:54 +0000

AltStyle によって変換されたページ (->オリジナル) /