import glob


def sorted_glob(pathname):
    """Return a sorted list of path names that match pathname.

    Otherwise, the glob module returns matching path names in
    arbitrary order because of its underlying usage of os.listdir().
    """
    return sorted(glob.iglob(pathname))