* xmlDictCreate: * * Create a new dictionary * * Returns the newly created dictionary, or NULL if an error occurred. */
| 261 | * Returns the newly created dictionary, or NULL if an error occurred. |
| 262 | */ |
| 263 | xmlDictPtr |
| 264 | xmlDictCreate(void) { |
| 265 | xmlDictPtr dict; |
| 266 | |
| 267 | xmlInitParser(); |
| 268 | |
| 269 | dict = xmlMalloc(sizeof(xmlDict)); |
| 270 | if (dict == NULL) |
| 271 | return(NULL); |
| 272 | dict->ref_counter = 1; |
| 273 | dict->limit = 0; |
| 274 | |
| 275 | dict->size = 0; |
| 276 | dict->nbElems = 0; |
| 277 | dict->table = NULL; |
| 278 | dict->strings = NULL; |
| 279 | dict->subdict = NULL; |
| 280 | dict->seed = xmlRandom(); |
| 281 | #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION |
| 282 | dict->seed = 0; |
| 283 | #endif |
| 284 | return(dict); |
| 285 | } |
| 286 | |
| 287 | /** |
| 288 | * xmlDictCreateSub: |
no test coverage detected