projects
/
oweals
/
musl.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
make pthread_create return EAGAIN on resource failure, as required by POSIX
[oweals/musl.git]
/
src
/
stdio
/
__stdio_write.c
1
#include "stdio_impl.h"
2
3
size_t __stdio_write(FILE *f, const unsigned char *buf, size_t len)
4
{
5
const unsigned char *stop = buf+len;
6
ssize_t cnt = 1;
7
for (; buf<stop && (cnt=__syscall_write(f->fd, buf, len))>0; buf+=cnt);
8
return len-(stop-buf);
9
}