summaryrefslogtreecommitdiffstats
path: root/src/lib/util/xmlfile.cpp
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2016-10-22 13:13:17 +0200
committer Miodrag Milanovic <mmicko@gmail.com>2016-10-22 13:13:17 +0200
commitddb290d5f615019c33c42b8d94e5a5254cabcf33 (patch)
treea70f688b0df3acd19da7b1151e5902e3c6af3fa5 /src/lib/util/xmlfile.cpp
parent333bff8de64dfaeb98134000412796b4fdef970b (diff)
NOTICE (TYPE NAME CONSOLIDATION)
Use standard uint64_t, uint32_t, uint16_t or uint8_t instead of UINT64, UINT32, UINT16 or UINT8 also use standard int64_t, int32_t, int16_t or int8_t instead of INT64, INT32, INT16 or INT8
Diffstat (limited to 'src/lib/util/xmlfile.cpp')
-rw-r--r--src/lib/util/xmlfile.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/lib/util/xmlfile.cpp b/src/lib/util/xmlfile.cpp
index b1ed844dc71..98689283c4e 100644
--- a/src/lib/util/xmlfile.cpp
+++ b/src/lib/util/xmlfile.cpp
@@ -32,7 +32,7 @@ struct xml_parse_info
XML_Parser parser;
xml_data_node * rootnode;
xml_data_node * curnode;
- UINT32 flags;
+ uint32_t flags;
};
@@ -103,7 +103,7 @@ static const char *copystring_lower(const char *input)
if (newstr != nullptr)
{
for (i = 0; input[i] != 0; i++)
- newstr[i] = tolower((UINT8)input[i]);
+ newstr[i] = tolower((uint8_t)input[i]);
newstr[i] = 0;
}
@@ -635,7 +635,7 @@ const char *xml_normalize_string(const char *string)
static void *expat_malloc(size_t size)
{
- UINT32 *result = (UINT32 *)malloc(size + 4 * sizeof(UINT32));
+ uint32_t *result = (uint32_t *)malloc(size + 4 * sizeof(uint32_t));
*result = size;
return &result[4];
}
@@ -651,7 +651,7 @@ static void *expat_malloc(size_t size)
static void expat_free(void *ptr)
{
if (ptr != nullptr)
- free(&((UINT32 *)ptr)[-4]);
+ free(&((uint32_t *)ptr)[-4]);
}
/**
@@ -672,7 +672,7 @@ static void *expat_realloc(void *ptr, size_t size)
return nullptr;
if (ptr != nullptr)
{
- UINT32 oldsize = ((UINT32 *)ptr)[-4];
+ uint32_t oldsize = ((uint32_t *)ptr)[-4];
memcpy(newptr, ptr, oldsize);
expat_free(ptr);
}
@@ -856,11 +856,11 @@ static void expat_element_end(void *data, const XML_Char *name)
char *end = start + strlen(start);
/* first strip leading spaces */
- while (*start && isspace((UINT8)*start))
+ while (*start && isspace((uint8_t)*start))
start++;
/* then strip trailing spaces */
- while (end > start && isspace((UINT8)end[-1]))
+ while (end > start && isspace((uint8_t)end[-1]))
end--;
/* if nothing left, just free it */