Commit Graph

3383 Commits

Author SHA1 Message Date
Rosen Penev
24a8139233 clang-tidy: fix badly indented if
Found with readability-misleading-indentation

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-14 17:51:45 +02:00
Rosen Penev
1b9b77c51f clang-tidy: add ending namespace comments
Found with google-readability-namespace-comments

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-14 17:34:09 +02:00
Rosen Penev
bf290e84e5 fix compilation with EXIV2_DEBUG_MESSAGES
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-14 17:23:10 +02:00
Miloš Komarčević
3416b631c5
Add Sony ARW compression to dict 2021-05-13 16:45:41 +02:00
Rosen Penev
fddb035106 clang-tidy: remove pointless const
Found with readability-avoid-const-params-in-decls

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-13 16:02:18 +02:00
Rosen Penev
80595f8468 clang-tidy: remove duplicate public
Found with readability-redundant-access-specifiers

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-13 11:52:02 +02:00
Kevin Backhouse
ca66136092 Use readOrThrow to check error conditions of iIo.read().
(cherry picked from commit 0f9eb74c44c908e170a64cab590949d53749af8e)
2021-05-13 11:51:15 +02:00
Rosen Penev
5dc4292b40 fix bad for range loop
This loop is supposed to break when it encounters a match.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-13 11:08:29 +02:00
Rosen Penev
091fd77885 clang-tidy: remove redundant member init
Found with readability-redundant-member-init

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 16:45:12 +02:00
Rosen Penev
674fdcd38b clang-tidy: fix declartation names
Found with readability-inconsistent-declaration-parameter-name

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 09:26:51 +02:00
Rosen Penev
2e73aa9dc0 default con/destructors in headers
Helps to optimize trivially destructable stuff.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 09:10:36 +02:00
Rosen Penev
428c436629 clang-tidy: simplify boolean expression
Found with readability-simplify-boolean-expr

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 07:12:15 +02:00
Rosen Penev
5d716c7df4 clang-tidy: empty() conversions
Found with readability-container-size-empty

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 07:12:15 +02:00
Rosen Penev
9642e3cceb clang-tidy: remove pointless string init
Found with readability-redundant-string-init

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 07:12:15 +02:00
Rosen Penev
143a1fbbe2 clang-tidy: don't use string compare
Found with readability-string-compare

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-12 07:12:15 +02:00
Rosen Penev
8337462032 clang-tidy: use empty() instead of comparing size
Found with readability-container-size-empty

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-11 22:02:47 +02:00
Rosen Penev
af7b2430c5 clang-tidy: use override
Found with modernize-use-override

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-11 17:39:59 +02:00
Rosen Penev
15f0a600ed clang-tidy: use default member init
Found with modernize-use-default-member-init

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-11 15:01:26 +02:00
Kevin Backhouse
170b18db74
Merge pull request #1621 from Exiv2/mergify/bp/main/pr-1591
Fix infinite loop caused by subBox with zero size. (backport #1591)
2021-05-11 12:28:03 +01:00
Luis Díaz Más
b4b8061478 Early access is always compiled 2021-05-11 08:25:42 +02:00
Kevin Backhouse
566ea272a1 Prevent large allocation.
(cherry picked from commit f154f0ae540deeb9251467187d01c2a5846d27b5)
2021-05-10 15:55:35 +02:00
Kevin Backhouse
aac34630d4 Fix infinite loop caused by subBox with zero size.
(cherry picked from commit 2736126e7b92c5654f56620c097f9a4580c0f73b)
2021-05-10 09:06:19 +00:00
Luis Díaz Más
9dbffa719b Add missing public headers to install target 2021-05-09 21:42:52 +02:00
Rosen Penev
5a9c29303e clang-tidy: remove pointless static
Found with readability-static-definition-in-anonymous-namespace

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-09 17:44:37 +02:00
Rosen Penev
bd6a996181 clang-tidy: use using
Found with modernize-use-using

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-09 17:42:51 +02:00
Rosen Penev
b3040da54c clang-tidy: don't check for NULL with delete
Found with readability-delete-null-pointer

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-09 17:42:26 +02:00
Rosen Penev
1dc1186760 clang-tidy: simplify boolean expressions
Found with readability-simplify-boolean-expr

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-09 17:30:46 +02:00
Rosen Penev
8128716287 clang-tidy: use = default
Found with modernize-use-equals-default

Ran through git clang-format

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-09 15:18:50 +02:00
Kevin Backhouse
57cad2619b Add bounds check in Jp2Image::doWriteMetadata().
(cherry picked from commit e6a0982f7cd9282052b6e3485a458d60629ffa0b)
2021-05-08 11:00:57 +00:00
Luis Díaz Más
b675c58bab Move include/CMake to src 2021-05-04 12:36:14 +02:00
Luis Díaz Más
1b4577904b Fix MSVC build 2021-05-03 17:41:55 +02:00
tbeu
bf0d8114c9 #525: Update comment and fix variable name 2021-05-03 17:41:55 +02:00
tbeu
94420ab591 Remove custom rwlock in favor of std::mutex of C++11
Current design on Windows was broken anyway, since legacy class `RWLock` does not implement a proper rwlock (shared read and exclusive write)

Once we are allowed using C++14 features, we can replace the `std::mutex` by `std::shared_timed_mutex` and the read-access locks by `std::shared_lock`.
Once we are allowed using C++17 features, we can replace the `std::mutex` by `std::shared_mutex` and the read-acces locks by `std::shared_lock`.
2021-05-03 17:41:55 +02:00
Rosen Penev
4ceb325c8f clang-tidy: range for loop conversions
Found with modernize-loop-convert

Ran through git clang-format.

Also removed several questionable loops and replaced with simpler
algorithms.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-03 14:50:04 +02:00
Rosen Penev
e93ad82734 clang-tidy: use braced init list
Found with modernize-return-braced-init-list

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-03 06:55:09 +02:00
Luis Díaz Más
294372f2ad cmake: revert change due to old cmake versions on CentOS & debian9 2021-05-03 06:40:02 +02:00
Luis Díaz Más
582edd399c cmake: ignore PDBs warnings on Win/Debug/Static buils 2021-05-03 06:40:02 +02:00
Luis Díaz Más
9de534976f msvc: fix compiler warning on x86 2021-05-03 06:40:02 +02:00
Luis Díaz Más
90dde02359 Win - Disable UNICODE which is failing at the moment 2021-05-03 06:40:02 +02:00
Rosen Penev
84220855b2 clang-tidy: use = delete
Found with modernize-use-equals-delete

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-03 06:34:47 +02:00
Luis Díaz Más
53f18cf408 conan: use cmake_paths generator instead of cmake
We also upgraded the xcode version on Travis-CI
2021-04-23 14:53:08 +02:00
Luis Díaz Más
f601d23d5e conan: update conan recipe versions 2021-04-23 14:53:08 +02:00
Kevin Backhouse
b3de96f4b4 Add more bounds checks in Jp2Image::encodeJp2Header 2021-04-22 21:14:50 +02:00
Luis Díaz Más
e366c786b9 Fix -Werror=shadow warning after recovering EPS 2021-04-22 20:24:59 +02:00
Luis Díaz Más
9b9154d137 fix warning (hiding local variable) 2021-04-22 18:40:03 +02:00
Luis Díaz Más
d5240a4bda eps: Fix code after usage of unique_ptr. Remove deprecation tags 2021-04-22 18:39:31 +02:00
Luis Díaz Más
8314030604 Revert "Remove deprecated EPS format"
This reverts commit 537cdad99e.
2021-04-22 18:39:31 +02:00
Kevin Backhouse
8388223deb Check that the string is properly terminated. 2021-04-22 11:38:49 +02:00
Kevin Backhouse
e8422732af Fix LGTM warning about format specifier
https://lgtm.com/projects/g/Exiv2/exiv2/rev/pr-6633ad1cc6e6c36bffd6655165c299c53e934b22
2021-04-22 11:38:49 +02:00
Kevin Backhouse
e97a9ff88a Fix signed/unsigned compiler warning. 2021-04-22 11:38:49 +02:00