MCPcopy Create free account
hub / github.com/OpenPrinting/cups / cupsLangFlush

Function cupsLangFlush

cups/language.c:380–412  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

378 */
379
380void
381cupsLangFlush(void)
382{
383 cups_lang_t *lang, /* Current language */
384 *next; /* Next language */
385
386
387 /*
388 * Free all languages in the cache...
389 */
390
391 _cupsMutexLock(&lang_mutex);
392
393 for (lang = lang_cache; lang != NULL; lang = next)
394 {
395 /*
396 * Free all messages...
397 */
398
399 _cupsMessageFree(lang->strings);
400
401 /*
402 * Then free the language structure itself...
403 */
404
405 next = lang->next;
406 free(lang);
407 }
408
409 lang_cache = NULL;
410
411 _cupsMutexUnlock(&lang_mutex);
412}
413
414
415/*

Callers

nothing calls this directly

Calls 3

_cupsMutexLockFunction · 0.85
_cupsMessageFreeFunction · 0.85
_cupsMutexUnlockFunction · 0.85

Tested by

no test coverage detected