diff --git a/daemon/db-daemon.c.orig b/daemon/db-daemon.c index bcf77df..c7b1a50 100644 --- a/daemon/db-daemon.c.orig +++ b/daemon/db-daemon.c @@ -156,7 +156,7 @@ int mainloop(struct db_daemon_data *d) { return 0; } d->multiread_requested = 1; - /* wait for complete response */ + /* wait for complete rsponse */ while (d->multiread_requested) { AcquireSRWLockExclusive(&d->lock); if (!handle_vchan_data(d)) { @@ -627,11 +627,8 @@ static int create_pidfile(struct db_daemon_data *d) { mode_t old_umask; struct stat stat_buf; - /* do not create pidfile for VM daemon - service is managed by systemd */ - if (!d->remote_name) - return 1; snprintf(pidfile_name, sizeof(pidfile_name), - "/var/run/qubes/qubesdb.%s.pid", d->remote_name); + "/var/run/qubes/qubes-db.pid"); old_umask = umask(0002); pidfile = fopen(pidfile_name, "w"); @@ -652,10 +649,8 @@ static void remove_pidfile(struct db_daemon_data *d) { struct stat stat_buf; /* no pidfile for VM daemon - service is managed by systemd */ - if (!d->remote_name) - return; snprintf(pidfile_name, sizeof(pidfile_name), - "/var/run/qubes/qubesdb.%s.pid", d->remote_name); + "/var/run/qubes/qubes-db.pid"); if (stat(pidfile_name, &stat_buf) == 0) { /* remove pidfile only if it's the one created this process */ @@ -763,7 +758,7 @@ int fuzz_main(int argc, char **argv) { exit(1); case 0: close(ready_pipe[0]); - snprintf(log_path, sizeof(log_path), "/var/log/qubes/qubesdb.%s.log", d.remote_name ? d.remote_name : "dom0"); + snprintf(log_path, sizeof(log_path), "/var/log/qubes/qubes-db.log"); close(0); old_umask = umask(0);