SYNOPSIS
#include <stdio.h>
FILE *fmemopen(void **buf, size_t size, const char *type);
DESCRIPTION
The
The file position indicator associated with the new stream is set to the start of the buffer.
PARAMETERS
- buf
-
Indicates the user buffer or NULL for system allocation.
- size
-
The size in bytes of the buffer passed, or the size to allocate if NULL is passed.
- type
-
Indicates a character string that specifies the desired type of file access. The first character of this string must be one of r (open for reading), w (open for writing), or a (open for writing at the end of file —append). After the first character, you can also add the + modifier that means to open for update, both reading and writing. The meaning of these flags is exactly as specified for
fopen() , except that w and w+ do not cause truncation of the file.
RETURN VALUES
If successful,
CONFORMANCE
IEEE Std 1003.1-2008 'POSIX.1'
MULTITHREAD SAFETY LEVEL
MT-Safe.
PORTING ISSUES
None.
AVAILABILITY
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
SEE ALSO
- Functions:
close() ,creat() ,dup() ,fclose() ,fdopen() ,fopen() ,freopen() ,fseek() ,open() ,pipe() ,write()
PTC MKS Toolkit 10.5 Documentation Build 40.