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

Function xmlValidNormalizeString

ThirdParty/libxml2/vtklibxml2/valid.c:3235–3256  ·  view source on GitHub ↗

* xmlValidNormalizeString: * @str: a string * * Normalize a string in-place. */

Source from the content-addressed store, hash-verified

3233 * Normalize a string in-place.
3234 */
3235static void
3236xmlValidNormalizeString(xmlChar *str) {
3237 xmlChar *dst;
3238 const xmlChar *src;
3239
3240 if (str == NULL)
3241 return;
3242 src = str;
3243 dst = str;
3244
3245 while (*src == 0x20) src++;
3246 while (*src != 0) {
3247 if (*src == 0x20) {
3248 while (*src == 0x20) src++;
3249 if (*src != 0)
3250 *dst++ = 0x20;
3251 } else {
3252 *dst++ = *src++;
3253 }
3254 }
3255 *dst = 0;
3256}
3257
3258static int
3259xmlIsDocNameStartChar(xmlDocPtr doc, int c) {

Calls

no outgoing calls

Tested by

no test coverage detected