def gen_mapname():
    """ Generate a uniq mapfile pathname. """
    filepath = None
    while (filepath is None) or (os.path.exists(os.path.join(config['mapfiles_dir'], filepath))):
        filepath = '%s.map' % _gen_string()
    return filepath