Fixed unlink of readonly mode socket

This commit is contained in:
Daniel P. Berrange 2007-03-06 16:51:48 +00:00
parent e8c6aa703a
commit 8cb208cd57
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
Tue Mar 06 11:47:12 EST 2007 Daniel P. Berrange <berrange@redhat.com>
* src/qemud.c: Unlink read-only socket upon startup (patch
from Rich Jones)
Mon Mar 05 12:19:42 EST 2007 Daniel P. Berrange <berrange@redhat.com> Mon Mar 05 12:19:42 EST 2007 Daniel P. Berrange <berrange@redhat.com>
* src/qemu_internal.c: Remove bogus ATTRIBUTE_UNUSED annotation * src/qemu_internal.c: Remove bogus ATTRIBUTE_UNUSED annotation

View File

@ -424,7 +424,7 @@ static int qemudInitPaths(struct qemud_server *server,
if (snprintf(roSockname, maxlen, "%s/run/libvirt/qemud-sock-ro", LOCAL_STATE_DIR) >= maxlen) if (snprintf(roSockname, maxlen, "%s/run/libvirt/qemud-sock-ro", LOCAL_STATE_DIR) >= maxlen)
goto snprintf_error; goto snprintf_error;
unlink(sockname); unlink(roSockname);
} else { } else {
if (!(pw = getpwuid(uid))) { if (!(pw = getpwuid(uid))) {
qemudLog(QEMUD_ERR, "Failed to find user record for uid '%d': %s", qemudLog(QEMUD_ERR, "Failed to find user record for uid '%d': %s",