summaryrefslogtreecommitdiffstats
path: root/parse-xml.c
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-06-16 12:52:39 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-06-16 14:41:56 -0700
commitccc9d800153ad11d8a2b54dc75fe8aefb5650dd3 (patch)
tree31a3638cd0885515709ab2aa55a3499746a1d2a8 /parse-xml.c
parentbd11988f74d2fcc7873df691e06a1279d7fd3228 (diff)
downloadsubsurface-ccc9d800153ad11d8a2b54dc75fe8aefb5650dd3.tar.gz
Remove all the no longer necessary code that aborts read of first V2 file
This was a poorly implemented hack when we executed the reverse geo lookup in the main thread and opening a V2 file could take a very long time. We need to do the "Welcome" message quite differently. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'parse-xml.c')
-rw-r--r--parse-xml.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/parse-xml.c b/parse-xml.c
index b00ce10a9..345bf61ed 100644
--- a/parse-xml.c
+++ b/parse-xml.c
@@ -22,9 +22,6 @@
int verbose, quit;
int metric = 1;
int last_xml_version = -1;
-bool abort_read_of_old_file = false;
-bool v2_question_shown = false;
-bool imported_via_xslt = false;
static xmlDoc *test_xslt_transforms(xmlDoc *doc, const char **params);
@@ -1718,14 +1715,6 @@ static bool entry(const char *name, char *buf)
if (!strncmp(name, "version.program", sizeof("version.program") - 1) ||
!strncmp(name, "version.divelog", sizeof("version.divelog") - 1)) {
last_xml_version = atoi(buf);
- if (last_xml_version < 3 && !v2_question_shown && !imported_via_xslt) {
- // let's ask the user what they want to do about reverse geo coding
- // and warn them that opening older XML files can take a while
- // since C code shouldn't call the UI we set a global flag and bail
- // from reading the file for now
- abort_read_of_old_file = true;
- return false;
- }
}
if (in_userid) {
try_to_fill_userid(name, buf);
@@ -1996,7 +1985,6 @@ int parse_xml_buffer(const char *url, const char *buffer, int size,
}
dive_end();
xmlFreeDoc(doc);
- imported_via_xslt = false;
return ret;
}
@@ -3213,7 +3201,6 @@ static xmlDoc *test_xslt_transforms(xmlDoc *doc, const char **params)
}
free((void *)attribute);
}
- imported_via_xslt = true;
xmlSubstituteEntitiesDefault(1);
xslt = get_stylesheet(info->file);
if (xslt == NULL) {