diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-04-21 02:44:45 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-04-21 02:44:45 +0200 |
commit | d63cf334575a2e038a0edaa3f9441cdad094d8d9 (patch) | |
tree | 24173dfa57e853f437df8935b9ad28899dc6359c /src/mds.c | |
parent | mds-server: parse command line arguments (diff) | |
download | mds-d63cf334575a2e038a0edaa3f9441cdad094d8d9.tar.gz mds-d63cf334575a2e038a0edaa3f9441cdad094d8d9.tar.bz2 mds-d63cf334575a2e038a0edaa3f9441cdad094d8d9.tar.xz |
unlink pid file on exit
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | src/mds.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -230,6 +230,11 @@ int main(int argc_, char** argv_) close(fd); unlink(pathname); + /* Remove PID file. */ + snprintf(pathname, sizeof(pathname) / sizeof(char), "%s/%u.pid", + MDS_RUNTIME_ROOT_DIRECTORY, display); + unlink(pathname); + return rc; } |