aboutsummaryrefslogtreecommitdiff
path: root/lib/unixctl.c
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2009-09-21 12:37:20 -0700
committerBen Pfaff <blp@nicira.com>2009-09-21 16:44:58 -0700
commit6a0061cbf5d8e2637040c54140c90e474b6543ca (patch)
tree1a1280d2a21b6ae503cd9ce074992bd6d1374a52 /lib/unixctl.c
parent411baaacb8672cd9b231328b77a5f1c8a11aad9c (diff)
fatal-signal: New function fatal_signal_unlink_file_now().
This is a helper function that combines two actions that callers commonly wanted. It will have an additional user in an upcoming commit.
Diffstat (limited to 'lib/unixctl.c')
-rw-r--r--lib/unixctl.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/unixctl.c b/lib/unixctl.c
index 7d6fdd67..e774ffe4 100644
--- a/lib/unixctl.c
+++ b/lib/unixctl.c
@@ -438,8 +438,7 @@ unixctl_server_destroy(struct unixctl_server *server)
}
close(server->fd);
- unlink(server->path);
- fatal_signal_remove_file_to_unlink(server->path);
+ fatal_signal_unlink_file_now(server->path);
free(server->path);
free(server);
}
@@ -504,8 +503,7 @@ void
unixctl_client_destroy(struct unixctl_client *client)
{
if (client) {
- unlink(client->bind_path);
- fatal_signal_remove_file_to_unlink(client->bind_path);
+ fatal_signal_unlink_file_now(client->bind_path);
free(client->bind_path);
free(client->connect_path);
fclose(client->stream);