]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/wordlist.cc
2 * Copyright (C) 1996-2023 The Squid Software Foundation and contributors
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
9 /* DEBUG: section 03 Configuration File Parsing */
16 wordlistDestroy(wordlist
** list
)
18 while (*list
!= nullptr) {
19 const char *k
= wordlistChopHead(list
);
25 wordlistAdd(wordlist
** list
, const char *key
)
28 list
= &(*list
)->next
;
30 *list
= new wordlist(key
);
35 wordlistCat(const wordlist
* w
, MemBuf
* mb
)
37 for (const auto &word
: *w
)
38 mb
->appendf("%s\n", word
);
42 wordlistChopHead(wordlist
**wl
)