MCPcopy Create free account
hub / github.com/Kitware/VTK / parsePath

Function parsePath

ThirdParty/libxml2/vtklibxml2/xmllint.c:201–225  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

199static int load_trace = 0;
200
201static
202void parsePath(const xmlChar *path) {
203 const xmlChar *cur;
204
205 if (path == NULL)
206 return;
207 while (*path != 0) {
208 if (nbpaths >= MAX_PATHS) {
209 fprintf(ERR_STREAM, "MAX_PATHS reached: too many paths\n");
210 return;
211 }
212 cur = path;
213 while ((*cur == ' ') || (*cur == PATH_SEPARATOR))
214 cur++;
215 path = cur;
216 while ((*cur != 0) && (*cur != ' ') && (*cur != PATH_SEPARATOR))
217 cur++;
218 if (cur != path) {
219 paths[nbpaths] = xmlStrndup(path, cur - path);
220 if (paths[nbpaths] != NULL)
221 nbpaths++;
222 path = cur;
223 }
224 }
225}
226
227static xmlExternalEntityLoader defaultEntityLoader = NULL;
228

Callers

nothing calls this directly

Calls 2

fprintfFunction · 0.85
xmlStrndupFunction · 0.85

Tested by

no test coverage detected