diff options
author | Stefan Metzmacher <metze@samba.org> | 2012-06-19 11:34:04 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2012-06-19 17:04:29 +0200 |
commit | e89150597ac659f738f24fe06ef3a17559a81862 (patch) | |
tree | f40dc96991fdd12349dedd79e8fb2ba24114cad4 /source3/lib | |
parent | 13cfe2504e17a3ab3c32d677e40ead5bd497432c (diff) | |
download | samba-e89150597ac659f738f24fe06ef3a17559a81862.tar.gz samba-e89150597ac659f738f24fe06ef3a17559a81862.tar.xz samba-e89150597ac659f738f24fe06ef3a17559a81862.zip |
Revert "s3-lib Remove unused sys_fcntl_long()"
This reverts commit 846a697e20478798288afb43cdb7a9f389a15c69.
This is still used in source3/smbd/oplock_irix.c
metze
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/system.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/source3/lib/system.c b/source3/lib/system.c index 92596a8d72e..3daa041a277 100644 --- a/source3/lib/system.c +++ b/source3/lib/system.c @@ -198,6 +198,20 @@ int sys_fcntl_ptr(int fd, int cmd, void *arg) return ret; } +/******************************************************************* +A fcntl wrapper that will deal with EINTR. +********************************************************************/ + +int sys_fcntl_long(int fd, int cmd, long arg) +{ + int ret; + + do { + ret = fcntl(fd, cmd, arg); + } while (ret == -1 && errno == EINTR); + return ret; +} + /**************************************************************************** Get/Set all the possible time fields from a stat struct as a timespec. ****************************************************************************/ |