qwrite

Performs a low-overhead write operation

Local Servers:blocking
Remote Servers:N/A
Classification:3.x, 4.x, 5.x, 6.x
Service:Advanced

Syntax

  #include <nwfileio.h>  
   
  int qwrite  (  
     int     fildes,   
     void   *buffer,   
     LONG    len,   
     LONG    position);  
  

Parameters

handle

(IN) Specifies the pertinent file handle.

buffer

(IN) Points to a buffer which contains the data.

len

(IN) Specifies the number of bytes to write.

position

(IN) Specifies the byte offset at which to start writing.

Return Values

If successful, this function returns the number of bytes written. If an error occurs, it returns -1 (EFAILURE) and errno and/or NWErrno can be set to:

Value

Name

Description

4

EBADF

Bad file number.

Other error codes as appropriate

Remarks

The qwrite function does not:

  • Perform parameter/context validation.

  • Maintain file position.

This function does not support:

  • O_APPEND

  • Standard I/O

  • Semaphore use of the handle

  • Streams

  • BSD Sockets

See Also

qread