summaryrefslogtreecommitdiffstats
path: root/daemons/clvmd/clvmd.c
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2012-03-01 21:12:37 +0000
committerZdenek Kabelac <zkabelac@redhat.com>2012-03-01 21:12:37 +0000
commitc45230754324ab46db86ee21036524ae0cb536e6 (patch)
treef0792343028bf76b54ebce5a5f43063cc00bd553 /daemons/clvmd/clvmd.c
parentbea2f619358d6aff06ad46be5913a3ac0a0d1fb8 (diff)
downloadlvm2-c45230754324ab46db86ee21036524ae0cb536e6.tar.gz
lvm2-c45230754324ab46db86ee21036524ae0cb536e6.tar.xz
lvm2-c45230754324ab46db86ee21036524ae0cb536e6.zip
Few more close and dev_close trace
Adding (void) where we cannot really report an error.
Diffstat (limited to 'daemons/clvmd/clvmd.c')
-rw-r--r--daemons/clvmd/clvmd.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/daemons/clvmd/clvmd.c b/daemons/clvmd/clvmd.c
index 2ee56108..f6ce3fdc 100644
--- a/daemons/clvmd/clvmd.c
+++ b/daemons/clvmd/clvmd.c
@@ -1052,11 +1052,11 @@ static void be_daemon(int timeout)
exit(2);
case 0: /* Child */
- close(child_pipe[0]);
+ (void) close(child_pipe[0]);
break;
default: /* Parent */
- close(child_pipe[1]);
+ (void) close(child_pipe[1]);
wait_for_child(child_pipe[0], timeout);
}
@@ -1140,8 +1140,8 @@ static int read_from_local_sock(struct local_client *thisfd)
struct local_client *lastfd = NULL;
struct local_client *free_fd = NULL;
- close(thisfd->bits.localsock.pipe_client->fd); /* Close pipe */
- close(thisfd->bits.localsock.pipe);
+ (void) close(thisfd->bits.localsock.pipe_client->fd); /* Close pipe */
+ (void) close(thisfd->bits.localsock.pipe);
/* Remove pipe client */
for (newfd = &local_client_head; newfd != NULL;
@@ -1329,8 +1329,8 @@ static int read_from_local_sock(struct local_client *thisfd)
.status = ENOMEM
};
- close(comms_pipe[0]);
- close(comms_pipe[1]);
+ (void) close(comms_pipe[0]);
+ (void) close(comms_pipe[1]);
send_message(&reply, sizeof(reply), our_csid,
thisfd->fd,
@@ -2107,7 +2107,9 @@ static int check_local_clvmd(void)
ret = -1;
}
- close(local_socket);
+ if (close(local_socket))
+ log_sys_error("close", "local socket");
+
return ret;
}