Sun Java System Web Server 7.0 Update 2 NSAPI Developer's Guide

system_fopenRW() Function

The system_fopenRW function opens the file identified by path in read-write mode and returns a valid file descriptor. If the file already exists, system_fopenRW does not truncate it. Use this function to open files that can be read and written by your program.

Syntax

SYS_FILE system_fopenRW(char *path);

Return Values

The system-independent file descriptor (SYS_FILE) if the open succeeds, or 0 if the open fails.

Parameters

char *path is the file name.

Example

SYS_FILE fd;
fd = system_fopenRO(pathname);
if (fd == SYS_ERROR_FD)    
break;

See Also

system_errmsg() Function, system_fopenRO() Function, system_fopenWA() Function, system_lseek() Function, system_fread() Function, system_fwrite() Function, system_fwrite_atomic() Function, system_flock() Function, system_ulock() Function, system_fclose() Function