summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDennis Nienhüser <nienhueser@kde.org>2016-09-27 18:46:31 (GMT)
committerDennis Nienhüser <nienhueser@kde.org>2016-09-27 18:46:31 (GMT)
commit2f642ecfa7328afa93e22f0ce49f65107dfbbf48 (patch)
tree24506a40f8f453795bbb7bace158f186be0c0cf8
parentcc8406238d29477478c0ade0672123d510bc5050 (diff)
Zoom level is always needed
-rw-r--r--tools/vectorosm-tilecreator/main.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/vectorosm-tilecreator/main.cpp b/tools/vectorosm-tilecreator/main.cpp
index 6dfb06b..ec0a76a 100644
--- a/tools/vectorosm-tilecreator/main.cpp
+++ b/tools/vectorosm-tilecreator/main.cpp
@@ -272,6 +272,11 @@ int main(int argc, char *argv[])
zoomLevels << level.toInt();
}
+ if (zoomLevels.isEmpty()) {
+ parser.showHelp(1);
+ return 1;
+ }
+
QString outputName;
if(parser.isSet("output")) {
outputName = parser.value("output");
@@ -299,7 +304,7 @@ int main(int argc, char *argv[])
ParsingRunnerManager manager(model.pluginManager());
bool const keepAllNodes = parser.isSet("keep-all-nodes");
- if (!zoomLevels.isEmpty() && *zoomLevels.cbegin() <= 9) {
+ if (*zoomLevels.cbegin() <= 9) {
auto map = open(inputFileName, manager);
VectorClipper processor(map.data());
GeoDataLatLonBox world(85.0, -85.0, 180.0, -180.0, GeoDataCoordinates::Degree);