The update-ldcache hook currently has one if statement to handle container root resolution errors and invalid root values (e.g. "" or /).
containerRootDir, err := s.GetContainerRoot()
if err != nil || containerRootDir == "" || containerRootDir == "/" {
return fmt.Errorf("failed to determined container root: %v", err)
}
An empty root or / can therefore produce a message ending in <nil>. This one error branch should be split into two.
The
update-ldcachehook currently has one if statement to handle container root resolution errors and invalid root values (e.g.""or/).An empty root or
/can therefore produce a message ending in<nil>. This one error branch should be split into two.