(self, path, rootdir="", volumes="", workdir="",
                   cont2host=False)
return ""
Find file in a path set such as PATH=/usr/bin:/bin
Find file in a path set such as PATH=/usr/bin:/bin
Find file in a path set such as PATH = / usr / bin : / bin
def _find_exec(self, path, rootdir="", volumes="", workdir="",
                   cont2host=False):
        """Find file in a path set such as PATH=/usr/bin:/bin"""
        for directory in path:
            if not directory:
                continue
            if directory == "." and workdir:
                directory = workdir
            elif directory == ".." and workdir:
                directory = workdir + "/.."
            if self.orig_filename.startswith("/"):
                exec_path = self.orig_filename
            else:
                exec_path = directory + "/" + self.orig_filename
            host_path = exec_path
            if rootdir:
                host_path = self._cont2host(exec_path, rootdir, volumes)
            if os.path.isfile(host_path) and os.access(host_path, os.X_OK):
                return host_path if cont2host else exec_path
        return ""
def _find_exec ( self , path , rootdir = "" , volumes = "" , workdir = "" , cont2host = False ) : for directory in path : if not directory : continue if directory == "." and workdir : directory = workdir elif directory == ".." and workdir : directory = workdir + "/.." if self . orig_filename . startswith ( "/" ) : exec_path = self . orig_filename else : exec_path = directory + "/" + self . orig_filename host_path = exec_path if rootdir : host_path = self . _cont2host ( exec_path , rootdir , volumes ) if os . path . isfile ( host_path ) and os . access ( host_path , os . X_OK ) : return host_path if cont2host else exec_path return ""