Whamcloud - gitweb
LU-25: Use LDLM_ASYNC with ldlm_cancel_lru to avoid blocking.
[fs/lustre-release.git] / lustre / tests / flocks_test.c
index 97890d8..fe2f045 100644 (file)
@@ -26,7 +26,7 @@
  * GPL HEADER END
  */
 /*
- * Copyright  2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
  */
 /*
@@ -240,7 +240,8 @@ int t2(int argc, char* argv[])
         }
 
         t_fcntl(fd, F_SETFL, O_APPEND);
-        if (!(rc = t_fcntl(fd, F_GETFL)) & O_APPEND) {
+        rc = t_fcntl(fd, F_GETFL);
+        if ((rc & O_APPEND) == 0) {
                 fprintf(stderr, "error get flag: ret %x\n", rc);
                 return EXIT_FAILURE;
         }