The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > High Level Programming
Google UNIX.COM



Thread: Negative Offset
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 05-09-2008
DNAx86 DNAx86 is offline
Registered User
 

Join Date: Jan 2008
Posts: 69
Negative Offset

Function: int fcntl(int fd, int cmd, struct flock * lock)

Data Type: struct flock
This structure is used with the fcntl function to describe a file lock. It has these members:

off_t l_start
This specifies the offset of the start of the region to which the lock applies, and is given in bytes relative to the point specified by l_whence member.

off_t l_len
This specifies the length of the region to be locked. A value of 0 is treated specially; it means the region extends to the end of the file.


Can I set negative offset to l_start?
Reply With Quote
Forum Sponsor