Revision c19f9810

b/lib/backend.py
1639 1639
  return detail
1640 1640

  
1641 1641

  
1642
def _OSOndiskAPIVersion(name, os_dir):
1642
def _OSOndiskAPIVersion(os_dir):
1643 1643
  """Compute and return the API version of a given OS.
1644 1644

  
1645
  This function will try to read the API version of the OS given by
1646
  the 'name' parameter and residing in the 'os_dir' directory.
1645
  This function will try to read the API version of the OS residing in
1646
  the 'os_dir' directory.
1647 1647

  
1648
  @type name: str
1649
  @param name: the OS name we should look for
1650 1648
  @type os_dir: str
1651
  @param os_dir: the directory inwhich we should look for the OS
1649
  @param os_dir: the directory in which we should look for the OS
1652 1650
  @rtype: tuple
1653 1651
  @return: tuple (status, data) with status denoting the validity and
1654 1652
      data holding either the vaid versions or an error message
......
1745 1743
  if os_dir is None:
1746 1744
    return False, "Directory for OS %s not found in search path" % name
1747 1745

  
1748
  status, api_versions = _OSOndiskAPIVersion(name, os_dir)
1746
  status, api_versions = _OSOndiskAPIVersion(os_dir)
1749 1747
  if not status:
1750 1748
    # push the error up
1751 1749
    return status, api_versions

Also available in: Unified diff