summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrés <andmarti@gmail.com>2023-06-01 19:10:49 -0300
committerAndrés <andmarti@gmail.com>2023-06-01 19:10:49 -0300
commitd08e90952e71eff80b8fd310ff94fb2b28657043 (patch)
tree715fe6f86885874bacf146de94c9db4aace94e61
parent91e08e397502d2da20169e0bb4a2c41aa9c38fba (diff)
work on issue 708
-rw-r--r--src/formats/xlsx.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/formats/xlsx.c b/src/formats/xlsx.c
index 048633c..227489a 100644
--- a/src/formats/xlsx.c
+++ b/src/formats/xlsx.c
@@ -158,7 +158,10 @@ char * get_xlsx_number_format_by_id(xmlDocPtr doc_styles, int id) {
// we go forward up to numFmts section
xmlNode * cur_node = xmlDocGetRootElement(doc_styles)->xmlChildrenNode;
- while (cur_node != NULL && !(cur_node->type == XML_ELEMENT_NODE && !strcmp((char *) cur_node->name, "numFmts")))
+ //while (cur_node != NULL && !(cur_node->type == XML_ELEMENT_NODE && !strcmp((char *) cur_node->name, "numFmts")))
+ while ((cur_node != NULL) && !(cur_node->type == XML_ELEMENT_NODE &&
+ (!strcmp((char *) cur_node->name, "numFmts") || !strcmp((char *) cur_node->name, "cellStyleXfs") ||
+ !strcmp((char *) cur_node->name, "cellXfs"))))
cur_node = cur_node->next;
cur_node = cur_node->xmlChildrenNode;