]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/plugins/radius/radiusclient/lib/lock.c
Whitespace tidying.
[ppp.git] / pppd / plugins / radius / radiusclient / lib / lock.c
index f78c5927a82b6d474c0756ff7baf1bd731edd9c1..83f79d83bb700fefda8fa012826de07ac828adc7 100644 (file)
@@ -1,10 +1,10 @@
 /*
- * $Id: lock.c,v 1.1 2002/01/22 16:03:02 dfs Exp $
+ * $Id: lock.c,v 1.2 2002/02/27 15:51:20 dfs Exp $
  *
  * Copyright (C) 1997 Lars Fenneberg
  *
- * See the file COPYRIGHT for the respective terms and conditions. 
- * If the file is missing contact me at lf@elemental.net 
+ * See the file COPYRIGHT for the respective terms and conditions.
+ * If the file is missing contact me at lf@elemental.net
  * and I'll send you a copy.
  *
  */
@@ -30,15 +30,15 @@ int do_lock_exclusive(int fd)
 {
        flock_t fl;
        int res;
-       
+
        memset((void *)&fl, 0, sizeof(fl));
-       
+
        fl.l_type = F_WRLCK;
        fl.l_whence = fl.l_start = 0;
        fl.l_len = 0; /* 0 means "to end of file" */
 
        res = fcntl(fd, F_SETLK, &fl);
-       
+
        if ((res == -1) && (errno == EAGAIN))
                errno = EWOULDBLOCK;
 
@@ -48,9 +48,9 @@ int do_lock_exclusive(int fd)
 int do_unlock(int fd)
 {
        flock_t fl;
-       
+
        memset((void *)&fl, 0, sizeof(fl));
-       
+
        fl.l_type = F_UNLCK;
        fl.l_whence = fl.l_start = 0;
        fl.l_len = 0; /* 0 means "to end of file" */
@@ -61,4 +61,3 @@ int do_unlock(int fd)
 #else
 YOU_LOOSE "need either flock(2) or fcntl(2)"
 #endif
-