MapFromKUID translates kuid, a UID in the root namespace, to a UID in ns.
(kuid KUID)
| 22 | |
| 23 | // MapFromKUID translates kuid, a UID in the root namespace, to a UID in ns. |
| 24 | func (ns *UserNamespace) MapFromKUID(kuid KUID) UID { |
| 25 | if ns.parent == nil { |
| 26 | return UID(kuid) |
| 27 | } |
| 28 | return UID(ns.mapID(&ns.uidMapFromParent, uint32(ns.parent.MapFromKUID(kuid)))) |
| 29 | } |
| 30 | |
| 31 | // MapFromKGID translates kgid, a GID in the root namespace, to a GID in ns. |
| 32 | func (ns *UserNamespace) MapFromKGID(kgid KGID) GID { |
no test coverage detected