This commit is contained in:
parent
3cc2e4b2a4
commit
80a897fbc5
@ -32,6 +32,9 @@ extern "C"
|
|||||||
/* Close a file and frees up its stream. */
|
/* Close a file and frees up its stream. */
|
||||||
int fclose(FILE* stream);
|
int fclose(FILE* stream);
|
||||||
|
|
||||||
|
/* Return the file descriptor associated with a stream. */
|
||||||
|
int fileno(FILE* stream);
|
||||||
|
|
||||||
/* Read arbitrarily sized items from a stream. */
|
/* Read arbitrarily sized items from a stream. */
|
||||||
size_t fread(void* buf, size_t size, size_t nmemb, FILE* stream);
|
size_t fread(void* buf, size_t size, size_t nmemb, FILE* stream);
|
||||||
|
|
||||||
|
@ -66,6 +66,11 @@ extern "C"
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int fileno(FILE* stream)
|
||||||
|
{
|
||||||
|
return stream->_fd;
|
||||||
|
}
|
||||||
|
|
||||||
size_t fread(void* buf, size_t size, size_t nmemb, FILE* stream)
|
size_t fread(void* buf, size_t size, size_t nmemb, FILE* stream)
|
||||||
{
|
{
|
||||||
if (size * nmemb == 0) return 0;
|
if (size * nmemb == 0) return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user