r3220: merging current 3.0 code to release branch
[tprouty/samba.git] / source / smbd / reply.c
index cdf607e27384d4dbc125dfe4f984afe3a6a2e2ec..845f05886700ba8279138cdb50c30a71228872a7 100644 (file)
@@ -4514,13 +4514,18 @@ int reply_lockingX(connection_struct *conn, char *inbuf,char *outbuf,int length,
        
        data = smb_buf(inbuf);
 
-       if (locktype & (LOCKING_ANDX_CANCEL_LOCK | LOCKING_ANDX_CHANGE_LOCKTYPE)) {
+       if (locktype & LOCKING_ANDX_CHANGE_LOCKTYPE) {
                /* we don't support these - and CANCEL_LOCK makes w2k
                   and XP reboot so I don't really want to be
                   compatible! (tridge) */
                return ERROR_NT(NT_STATUS_NOT_SUPPORTED);
        }
        
+       if (locktype & LOCKING_ANDX_CANCEL_LOCK) {
+               /* Need to make this like a cancel.... JRA. */
+               return ERROR_NT(NT_STATUS_UNSUCCESSFUL);
+       }
+       
        /* Check if this is an oplock break on a file
           we have granted an oplock on.
        */