diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2014-07-26 06:17:25 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2014-07-26 06:17:25 -0700 |
commit | 9e9f8582a893f1e97b1f8955f69b96f969ee1f85 (patch) | |
tree | ef8b4c36f8b88d1273572b8140a8651854b65e6b /src/filelock.c | |
parent | 54e3f15626296c1ece932852df2b3d4938b0b44a (diff) | |
download | emacs-9e9f8582a893f1e97b1f8955f69b96f969ee1f85.tar.gz |
Revert previous change.
There is certainly nothing wrong with writing code like 'lo <= i
&& i <= hi', even if LO happens to a constant. There isn't even
anything wrong in general with writing 'a <= b' if A happens to
be a constant. At any rate stylistic changes shouldn't
be done like this without discussion.
Diffstat (limited to 'src/filelock.c')
-rw-r--r-- | src/filelock.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/filelock.c b/src/filelock.c index bbc616206d7..f857c488143 100644 --- a/src/filelock.c +++ b/src/filelock.c @@ -504,7 +504,7 @@ read_lock_data (char *lfname, char lfinfo[MAX_LFINFO + 1]) && errno == EINVAL) { int fd = emacs_open (lfname, O_RDONLY | O_BINARY | O_NOFOLLOW, 0); - if (fd >= 0) + if (0 <= fd) { /* Use read, not emacs_read, since FD isn't unwind-protected. */ ptrdiff_t read_bytes = read (fd, lfinfo, MAX_LFINFO + 1); @@ -713,7 +713,7 @@ lock_file (Lisp_Object fn) } /* Try to lock the lock. */ - if (lock_if_free (&lock_info, lfname) > 0) + if (0 < lock_if_free (&lock_info, lfname)) { /* Someone else has the lock. Consider breaking it. */ Lisp_Object attack; |