aboutsummaryrefslogtreecommitdiff
path: root/src/apps
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-03-04 11:39:14 +0100
committerGitHub <noreply@github.com>2021-03-04 11:39:14 +0100
commitf278b5bee641dd94245ed54f4eb75e29c3d4d993 (patch)
treeec5700b9a252f27670e821da9f821c8bed867052 /src/apps
parent948f39a4da835d9e770ece735d58ac488591bd76 (diff)
parent095731d53405309c38bebe31af51d141f6319f1a (diff)
downloadPROJ-f278b5bee641dd94245ed54f4eb75e29c3d4d993.tar.gz
PROJ-f278b5bee641dd94245ed54f4eb75e29c3d4d993.zip
Merge pull request #2551 from rouault/clang_format
Reformat code with clang-format-10 from ubuntu 20.04
Diffstat (limited to 'src/apps')
-rw-r--r--src/apps/projinfo.cpp13
-rw-r--r--src/apps/projsync.cpp7
2 files changed, 9 insertions, 11 deletions
diff --git a/src/apps/projinfo.cpp b/src/apps/projinfo.cpp
index 8d389019..8c266e94 100644
--- a/src/apps/projinfo.cpp
+++ b/src/apps/projinfo.cpp
@@ -187,8 +187,8 @@ static BaseObjectNNPtr buildObject(
try {
auto tokens = split(l_user_string, ':');
if (kind == "operation" && tokens.size() == 2) {
- auto urn = "urn:ogc:def:coordinateOperation:" + tokens[0] + "::" +
- tokens[1];
+ auto urn = "urn:ogc:def:coordinateOperation:" + tokens[0] +
+ "::" + tokens[1];
obj = createFromUserInput(urn, dbContext).as_nullable();
} else if ((kind == "ellipsoid" || kind == "datum" ||
kind == "ensemble") &&
@@ -1214,11 +1214,10 @@ int main(int argc, char **argv) {
if (crs) {
try {
auto res = crs->identify(
- dbContext
- ? AuthorityFactory::create(
- NN_NO_CHECK(dbContext), authority)
- .as_nullable()
- : nullptr);
+ dbContext ? AuthorityFactory::create(
+ NN_NO_CHECK(dbContext), authority)
+ .as_nullable()
+ : nullptr);
std::cout << std::endl;
std::cout
<< "Identification match count: " << res.size()
diff --git a/src/apps/projsync.cpp b/src/apps/projsync.cpp
index 7f3d5e56..ec4d00fd 100644
--- a/src/apps/projsync.cpp
+++ b/src/apps/projsync.cpp
@@ -55,7 +55,7 @@ class ParsingException : public std::exception {
explicit ParsingException(const char *msg) : msg_(msg) {}
const char *what() const noexcept override { return msg_.c_str(); }
};
-}
+} // namespace
// ---------------------------------------------------------------------------
@@ -514,9 +514,8 @@ int main(int argc, char *argv[]) {
std::cout << url << "... (" << i + 1 << " / "
<< to_download.size() << ")" << std::endl;
}
- if (!dryRun &&
- !proj_download_file(ctx, url.c_str(), false, nullptr,
- nullptr)) {
+ if (!dryRun && !proj_download_file(ctx, url.c_str(), false, nullptr,
+ nullptr)) {
std::cerr << "Cannot download " << url << std::endl;
std::exit(1);
}