mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Our geom withering function could take some time before geom with its
providers and consumers will be destroyed. Before take some actions with a geom, check that it is not destroyed at the moment. Tested by: nwhitehorn MFC after: 1 week
This commit is contained in:
parent
0c4b17e1e7
commit
aea26bc05a
1 changed files with 4 additions and 0 deletions
|
|
@ -451,6 +451,10 @@ g_part_parm_geom(struct gctl_req *req, const char *name, struct g_geom **v)
|
|||
gctl_error(req, "%d %s '%s'", EINVAL, name, gname);
|
||||
return (EINVAL);
|
||||
}
|
||||
if ((gp->flags & G_GEOM_WITHER) != 0) {
|
||||
gctl_error(req, "%d %s", ENXIO, gname);
|
||||
return (ENXIO);
|
||||
}
|
||||
*v = gp;
|
||||
return (0);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue