* xmlFreeID: * @not: A id * * Deallocate the memory used by an id definition */
| 2286 | * Deallocate the memory used by an id definition |
| 2287 | */ |
| 2288 | static void |
| 2289 | xmlFreeID(xmlIDPtr id) { |
| 2290 | xmlDictPtr dict = NULL; |
| 2291 | |
| 2292 | if (id == NULL) return; |
| 2293 | |
| 2294 | if (id->doc != NULL) |
| 2295 | dict = id->doc->dict; |
| 2296 | |
| 2297 | if (id->value != NULL) |
| 2298 | DICT_FREE(id->value) |
| 2299 | if (id->name != NULL) |
| 2300 | DICT_FREE(id->name) |
| 2301 | if (id->attr != NULL) { |
| 2302 | id->attr->id = NULL; |
| 2303 | id->attr->atype = 0; |
| 2304 | } |
| 2305 | |
| 2306 | xmlFree(id); |
| 2307 | } |
| 2308 | |
| 2309 | |
| 2310 | /** |
no outgoing calls
no test coverage detected