Loading hw/9pfs/9p-local.c +4 −0 Original line number Diff line number Diff line Loading @@ -1465,6 +1465,10 @@ static void local_cleanup(FsContext *ctx) { LocalData *data = ctx->private; if (!data) { return; } close(data->mountfd); g_free(data); } Loading hw/9pfs/9p-proxy.c +4 −0 Original line number Diff line number Diff line Loading @@ -1185,6 +1185,10 @@ static void proxy_cleanup(FsContext *ctx) { V9fsProxy *proxy = ctx->private; if (!proxy) { return; } g_free(proxy->out_iovec.iov_base); g_free(proxy->in_iovec.iov_base); if (ctx->export_flags & V9FS_PROXY_SOCK_NAME) { Loading hw/9pfs/9p.c +6 −10 Original line number Diff line number Diff line Loading @@ -3637,27 +3637,23 @@ int v9fs_device_realize_common(V9fsState *s, const V9fsTransport *t, s->ctx.fst = &fse->fst; fsdev_throttle_init(s->ctx.fst); v9fs_path_free(&path); rc = 0; out: if (rc) { if (s->ops && s->ops->cleanup && s->ctx.private) { s->ops->cleanup(&s->ctx); v9fs_device_unrealize_common(s, NULL); } g_free(s->tag); g_free(s->ctx.fs_root); v9fs_path_free(&path); } return rc; } void v9fs_device_unrealize_common(V9fsState *s, Error **errp) { if (s->ops->cleanup) { if (s->ops && s->ops->cleanup) { s->ops->cleanup(&s->ctx); } if (s->ctx.fst) { fsdev_throttle_cleanup(s->ctx.fst); } g_free(s->tag); g_free(s->ctx.fs_root); } Loading Loading
hw/9pfs/9p-local.c +4 −0 Original line number Diff line number Diff line Loading @@ -1465,6 +1465,10 @@ static void local_cleanup(FsContext *ctx) { LocalData *data = ctx->private; if (!data) { return; } close(data->mountfd); g_free(data); } Loading
hw/9pfs/9p-proxy.c +4 −0 Original line number Diff line number Diff line Loading @@ -1185,6 +1185,10 @@ static void proxy_cleanup(FsContext *ctx) { V9fsProxy *proxy = ctx->private; if (!proxy) { return; } g_free(proxy->out_iovec.iov_base); g_free(proxy->in_iovec.iov_base); if (ctx->export_flags & V9FS_PROXY_SOCK_NAME) { Loading
hw/9pfs/9p.c +6 −10 Original line number Diff line number Diff line Loading @@ -3637,27 +3637,23 @@ int v9fs_device_realize_common(V9fsState *s, const V9fsTransport *t, s->ctx.fst = &fse->fst; fsdev_throttle_init(s->ctx.fst); v9fs_path_free(&path); rc = 0; out: if (rc) { if (s->ops && s->ops->cleanup && s->ctx.private) { s->ops->cleanup(&s->ctx); v9fs_device_unrealize_common(s, NULL); } g_free(s->tag); g_free(s->ctx.fs_root); v9fs_path_free(&path); } return rc; } void v9fs_device_unrealize_common(V9fsState *s, Error **errp) { if (s->ops->cleanup) { if (s->ops && s->ops->cleanup) { s->ops->cleanup(&s->ctx); } if (s->ctx.fst) { fsdev_throttle_cleanup(s->ctx.fst); } g_free(s->tag); g_free(s->ctx.fs_root); } Loading