diff options
author | Jeremy Allison <jra@samba.org> | 2001-09-05 00:05:07 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-09-05 00:05:07 +0000 |
commit | 8fad5177701c1738a7f5bdd7c0082ef23a00b876 (patch) | |
tree | 0c90a67b61e087b20813a00b16d912797baed803 /source/locking | |
parent | c65e8db7ae765f844f8b0adb1e5de3651561ad96 (diff) | |
download | samba-8fad5177701c1738a7f5bdd7c0082ef23a00b876.tar.gz samba-8fad5177701c1738a7f5bdd7c0082ef23a00b876.tar.xz samba-8fad5177701c1738a7f5bdd7c0082ef23a00b876.zip |
NFS v2 can return ENOLCK when greater than 31 bit offsets are used.
Treat this the same as an EFBIG error.
Jeremy
Diffstat (limited to 'source/locking')
-rw-r--r-- | source/locking/posix.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/locking/posix.c b/source/locking/posix.c index 6a621200ca0..b2ffbeda8ff 100644 --- a/source/locking/posix.c +++ b/source/locking/posix.c @@ -705,10 +705,10 @@ static BOOL posix_fcntl_lock(files_struct *fsp, int op, SMB_OFF_T offset, SMB_OF ret = conn->vfs_ops.lock(fsp,fsp->fd,op,offset,count,type); - if (!ret && (errno == EFBIG)) { + if (!ret && ((errno == EFBIG) || (errno == ENOLCK))) { if( DEBUGLVL( 0 )) { dbgtext("posix_fcntl_lock: WARNING: lock request at offset %.0f, length %.0f returned\n", (double)offset,(double)count); - dbgtext("a 'file too large' error. This can happen when using 64 bit lock offsets\n"); + dbgtext("an %s error. This can happen when using 64 bit lock offsets\n", strerror(errno)); dbgtext("on 32 bit NFS mounted file systems. Retrying with 32 bit truncated length.\n"); } /* 32 bit NFS file system, retry with smaller offset */ |