aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xenstore/utils.c
diff options
context:
space:
mode:
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-08-08 09:13:19 +0000
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-08-08 09:13:19 +0000
commit0996bc07b90b939292c1ae6baa0bd108675d0ba4 (patch)
treea83c7841d98a0484965d2d435eb914385ada7140 /tools/xenstore/utils.c
parent9174fdfbfc3a340b4002d8eb71390d4cc203f1d6 (diff)
downloadxen-0996bc07b90b939292c1ae6baa0bd108675d0ba4.tar.gz
xen-0996bc07b90b939292c1ae6baa0bd108675d0ba4.tar.bz2
xen-0996bc07b90b939292c1ae6baa0bd108675d0ba4.zip
1) More testing: include tests which I forgot in previous patch, remove
xs_watch_stress, reduce cycles in "make check" random test. 2) xs_crashme: corrupt random packets going to xenstored, watch it crash. 3) Handle second input from before we finished output on first one. 4) Fix bug where one-arg operations are given zero args. 5) Fix bug where SET_PERMS fails after blocking on transaction. 6) Fix memory leak when DIRECTORY op given no argument. 7) Fail on first memory leak, for better testing. 8) Fix missing waiting_for_ack initialization for new connections. 9) Ensure all input and output is handled for domains so we don't stall. 10) Fix overrun bug in xs_count_strings on non-nul-terminated strings. 11) New test for clients which write without waiting for response. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'tools/xenstore/utils.c')
-rw-r--r--tools/xenstore/utils.c15
1 files changed, 0 insertions, 15 deletions
diff --git a/tools/xenstore/utils.c b/tools/xenstore/utils.c
index cc5e0bc5f2..0b1ac8aedd 100644
--- a/tools/xenstore/utils.c
+++ b/tools/xenstore/utils.c
@@ -84,9 +84,6 @@ void *malloc_nofail(size_t size)
void daemonize(void)
{
pid_t pid;
- int fd;
- size_t len;
- char buf[100];
/* Separate from our parent via fork, so init inherits us. */
if ((pid = fork()) < 0)
@@ -104,18 +101,6 @@ void daemonize(void)
chdir("/");
/* Discard our parent's old-fashioned umask prejudices. */
umask(0);
-
- fd = open("/var/run/xenstored.pid", O_RDWR | O_CREAT);
- if (fd == -1) {
- exit(1);
- }
-
- if (lockf(fd, F_TLOCK, 0) == -1) {
- exit(1);
- }
-
- len = sprintf(buf, "%d\n", getpid());
- write(fd, buf, len);
}