mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 13:33:09 +07:00
Fix unchecked return value, found by Coverity Scan
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
+4
-2
@@ -62,8 +62,10 @@ int iwatch_init(struct iwatch *iw)
|
||||
* reconf of systems with lots of services.
|
||||
*/
|
||||
len = sizeof(sz);
|
||||
if (!getsockopt(iw->fd, SOL_SOCKET, SO_RCVBUF, &sz, &len))
|
||||
setsockopt(iw->fd, SOL_SOCKET, SO_RCVBUF, &sz, sizeof(sz));
|
||||
if (!getsockopt(iw->fd, SOL_SOCKET, SO_RCVBUF, &sz, &len)) {
|
||||
if (setsockopt(iw->fd, SOL_SOCKET, SO_RCVBUF, &sz, sizeof(sz)))
|
||||
_pe("Failed increasing size of inotify socket");
|
||||
}
|
||||
|
||||
initialized = 1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user