[Virtio-fs] [PATCH v2 07/10] virtiofsd: Use qemu_get_runtime_dir()
Akihiko Odaki
akihiko.odaki at daynix.com
Thu Nov 10 10:06:26 UTC 2022
qemu_get_runtime_dir() is used to construct the path to a lock file.
Signed-off-by: Akihiko Odaki <akihiko.odaki at daynix.com>
---
tools/virtiofsd/fuse_virtio.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tools/virtiofsd/fuse_virtio.c b/tools/virtiofsd/fuse_virtio.c
index 9368e292e4..b9eeed85e6 100644
--- a/tools/virtiofsd/fuse_virtio.c
+++ b/tools/virtiofsd/fuse_virtio.c
@@ -901,12 +901,12 @@ static bool fv_socket_lock(struct fuse_session *se)
{
g_autofree gchar *sk_name = NULL;
g_autofree gchar *pidfile = NULL;
- g_autofree gchar *state = NULL;
+ g_autofree gchar *run = NULL;
g_autofree gchar *dir = NULL;
Error *local_err = NULL;
- state = qemu_get_local_state_dir();
- dir = g_build_filename(state, "run", "virtiofsd", NULL);
+ run = qemu_get_runtime_dir();
+ dir = g_build_filename(run, "virtiofsd", NULL);
if (g_mkdir_with_parents(dir, S_IRWXU) < 0) {
fuse_log(FUSE_LOG_ERR, "%s: Failed to create directory %s: %s\n",
--
2.38.1
More information about the Virtio-fs
mailing list