]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
remove unused `cfg_map_add()` function
authorColin Vidal <colin@isc.org>
Tue, 19 May 2026 13:03:36 +0000 (15:03 +0200)
committerColin Vidal <colin@isc.org>
Thu, 21 May 2026 14:04:01 +0000 (16:04 +0200)
Function `cfg_map_add()` was unused, it is now removed.

lib/isccfg/include/isccfg/cfg.h
lib/isccfg/parser.c

index 5012f492171730c6cd36a2e168d241944cb748e7..592f538cd008a99b640ecde65e1601bd8f41b61f 100644 (file)
@@ -219,17 +219,6 @@ cfg_map_get(const cfg_obj_t *mapobj, const char *name, const cfg_obj_t **obj);
  * \li     #ISC_R_NOTFOUND                 - name not found in map
  */
 
-isc_result_t
-cfg_map_add(cfg_obj_t *mapobj, cfg_obj_t *obj, const char *clause);
-/*%<
- * Add the object 'obj' to the specified clause in mapbody 'mapobj'.
- * Used for adding new zones.
- *
- * Require:
- * \li     'obj' is a valid cfg_obj_t.
- * \li     'mapobj' is a valid cfg_obj_t of type map.
- */
-
 const cfg_obj_t *
 cfg_map_getname(const cfg_obj_t *mapobj);
 /*%<
index 83722cb858f4827ead7c5952086fdcd076b6c626..c19239e37cbffc3aa58f06ce788394672da866dd 100644 (file)
@@ -4042,23 +4042,6 @@ map_define(cfg_obj_t *mapobj, cfg_obj_t *obj, const cfg_clausedef_t *clause) {
        return result;
 }
 
-isc_result_t
-cfg_map_add(cfg_obj_t *mapobj, cfg_obj_t *obj, const char *clausename) {
-       const cfg_clausedef_t *clause;
-
-       REQUIRE(VALID_CFGOBJ(obj));
-       REQUIRE(VALID_CFGOBJ(mapobj));
-       REQUIRE(mapobj->type->rep == &cfg_rep_map);
-       REQUIRE(clausename != NULL);
-
-       clause = cfg_map_findclause(mapobj->type, clausename);
-       if (clause == NULL || clause->name == NULL) {
-               return ISC_R_FAILURE;
-       }
-
-       return map_define(mapobj, obj, clause);
-}
-
 isc_result_t
 cfg_map_addclone(cfg_obj_t *map, const cfg_obj_t *obj,
                 const cfg_clausedef_t *clause) {