]> wimlib.net Git - wimlib/blobdiff - src/xml.c
xml.c: pass non-const xmlNode to xmlHasProp()
[wimlib] / src / xml.c
index 6ce578d9b17d5151b0977a9123ca711c28333839..18721b1467db45a3b2278dc82d9aa8302058c390 100644 (file)
--- a/src/xml.c
+++ b/src/xml.c
@@ -5,7 +5,7 @@
  */
 
 /*
- * Copyright (C) 2012, 2013, 2015 Eric Biggers
+ * Copyright (C) 2012-2016 Eric Biggers
  *
  * This file is free software; you can redistribute it and/or modify it under
  * the terms of the GNU Lesser General Public License as published by the Free
@@ -343,14 +343,14 @@ alloc_wim_xml_info(void)
 }
 
 static bool
-parse_index(xmlChar **pp, uint32_t *index_ret)
+parse_index(xmlChar **pp, u32 *index_ret)
 {
        xmlChar *p = *pp;
-       uint32_t index = 0;
+       u32 index = 0;
 
        *p++ = '\0'; /* overwrite '[' */
        while (*p >= '0' && *p <= '9') {
-               uint32_t n = (index * 10) + (*p++ - '0');
+               u32 n = (index * 10) + (*p++ - '0');
                if (n < index)
                        return false;
                index = n;
@@ -393,7 +393,7 @@ do_xml_path_walk(xmlNode *node, const xmlChar *path, bool create,
        while (c != '\0') {
                const xmlChar *name;
                xmlNode *child;
-               uint32_t index = 1;
+               u32 index = 1;
 
                /* We have another path component.  */
 
@@ -1027,7 +1027,7 @@ xml_print_image_info(struct wim_xml_info *info, int image)
  *----------------------------------------------------------------------------*/
 
 static int
-image_node_get_index(const xmlNode *node)
+image_node_get_index(xmlNode *node)
 {
        u64 v = node_get_number((const xmlNode *)xmlHasProp(node, "INDEX"), 10);
        return min(v, INT_MAX);