]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
libmount: add note about flock() to docs
authorKarel Zak <kzak@redhat.com>
Thu, 2 Apr 2015 10:30:26 +0000 (12:30 +0200)
committerKarel Zak <kzak@redhat.com>
Wed, 29 Apr 2015 10:30:16 +0000 (12:30 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
libmount/src/lock.c

index 8fc971617fe9563cac81f690940c19d1a8eb9c88..0d943295aa6c825da64355505eae4542a0c512f8 100644 (file)
@@ -511,6 +511,10 @@ failed:
  *   3. a) link() success: setups F_SETLK lock (see fcnlt(2))
  *      b) link() failed:  wait (max 30s) on F_SETLKW lock, goto 2.
  *
+ * Note that when the lock is used by mnt_update_table() interface then libmount
+ * uses flock() for private library file /run/mount/utab. The fcnlt(2) is used only
+ * for backwardly compatible stuff like /etc/mtab.
+ *
  * Returns: 0 on success or negative number in case of error (-ETIMEOUT is case
  * of stale lock file).
  */