提交 b980c34d 编写于 作者: M Maxim Nestratov 提交者: Michal Privoznik

parallels: fix home directory for VMs

Failures of parallelsStorageOpen occured because we incorrectly treated
path to VM' configuration file as a directory. Now initialization of
parallels VM domains home directory is fixed.
Signed-off-by: NMaxim Nestratov <mnestratov@parallels.com>
上级 2765fb72
......@@ -1245,6 +1245,14 @@ prlsdkLoadDomain(parallelsConnPtr privconn,
pret = PrlVmCfg_GetHomePath(sdkdom, pdom->home, &buflen);
prlsdkCheckRetGoto(pret, error);
/* For VMs pdom->home is actually /directory/config.pvs */
if (!IS_CT(def)) {
/* Get rid of /config.pvs in path string */
char *s = strrchr(pdom->home, '/');
if (s)
*s = '\0';
}
if (olddom) {
/* assign new virDomainDef without any checks */
/* we can't use virDomainObjAssignDef, because it checks
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册