From: Pavel Sanda Date: Thu, 27 Mar 2014 08:10:59 +0000 (-0700) Subject: Squash gcc warning. X-Git-Tag: 2.1.0~106 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=0f8a2d2860c86c859064546876b2c99992dfd50d;p=features.git Squash gcc warning. http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg183142.html --- diff --git a/src/support/filetools.cpp b/src/support/filetools.cpp index 0012481681..92aeaf7fb4 100644 --- a/src/support/filetools.cpp +++ b/src/support/filetools.cpp @@ -1080,8 +1080,9 @@ int fileLock(const char * lock_file) void fileUnlock(int fd, const char * /* lock_file*/) { #if defined(HAVE_LOCKF) - if ( fd >= 0) { - (void) lockf(fd, F_ULOCK, 0); + if (fd >= 0) { + if (lockf(fd, F_ULOCK, 0)) + LYXERR0("Can't unlock the file."); close(fd); } #endif