Changeset 40

Show
Ignore:
Timestamp:
06/04/08 16:47:27 (6 months ago)
Author:
jtang
Message:

Clarified how sipc_recv_data() should be used if the IPC is shared memory.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/libsipc/man/man3/sipc_recv_data.3

    r38 r40  
    2929allocates the buffer used to store received data; it is the 
    3030responsibility of the caller to \fBfree()\fR this data afterwards. 
    31 Otherwise, the shared memory reader must call \fBsipc_shm_recv_done\fR 
    32 to unblock the sender, and no freeing should occur. 
     31.P 
     32Otherwise if the IPC channel is shared memory, the returned 
     33.I data 
     34pointer points into the shared memory buffer. 
     35The reader must call \fBsipc_shm_recv_done\fR() to unblock the sender, 
     36and 
     37.I data 
     38should not be freed. 
     39After calling \fBsipc_recv_data\fR(), there must be a call to 
     40\fBsipc_shm_recv_done\fR() prior to further invocations of 
     41\fBsipc_recv_data\fR(), else undefined behavior results. 
     42.P 
     43This function blocks if no data is in the IPC channel. 
    3344.SH "RETURN VALUE" 
    3445This function returns 0 on success, \-1 on error.