Rosen Penev
2fa84f4bab
remove using
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-08-21 14:37:18 -07:00
Rosen Penev
b8855fb3b5
misc sonarlint cleanups
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-08-05 01:01:25 -07:00
Rosen Penev
3ae1d3b48e
return make_unique directly
...
Simpler
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-07-24 23:00:02 -07:00
Peter
dc4ae73013
Add tag description option to exiv2 app ( #2279 )
...
* Add `tagDesc()` to (Exif|Xmp|Iptc) Datums and Keys
* Add `--Print d` option to exiv2 app
* Add testing for all exiv2 application `--Print` options
* Update manpage
2022-07-12 15:31:43 +01:00
Kevin Backhouse
3ef783e02a
Convert IfdId and SectionId to enum classes.
2022-07-11 22:37:52 +01:00
Kevin Backhouse
3f7cb78a3b
Move enums from tags_int.hpp to tags.hpp
2022-07-08 12:03:53 +01:00
Rosen Penev
cf963e9e4d
clang-tidy: C casts to C++
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-05-21 17:58:10 -07:00
Luis Díaz Más
6e9eca445a
Merge pull request #2177 from neheb/1
...
clang-tidy and manual stuff
2022-04-06 14:53:33 +02:00
Luis Díaz Más
bd68c14de5
Detect integer-overflow and throw in that case
2022-04-04 09:18:02 +02:00
Rosen Penev
9f67620503
clang-tidy: add more nodiscard
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-04-01 16:38:03 -07:00
Rosen Penev
5d5354edee
clang-tidy: C array to std::array conversions
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-18 13:19:45 +01:00
Luis Díaz Más
30bf563f4d
Update .clang-format file & apply clang-format to whole project
2022-03-16 22:30:53 +01:00
Rosen Penev
b2b6d834ba
some std::array conversions ( #2148 )
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-15 10:17:06 +01:00
Luis Díaz Más
573c3c79fc
Merge pull request #2145 from Exiv2/mainSizeT_n
...
More migration to size_t
2022-03-14 21:42:43 +01:00
Jim Easterbrook
04ae6c2c4c
Add key name to "Value not set" error message ( #2149 )
...
The error typically occurs when writeMetadata() is called. It's easier
to find the problem if you know which datum hasn't had a value set.
2022-03-14 13:17:54 +01:00
Luis Diaz
7576a2757b
More size_t for sizes
2022-03-14 11:50:42 +01:00
Luis Diaz
137ea080b5
Change Metadatum::size() return value from long to size_t
2022-03-14 11:47:15 +01:00
Luis Diaz
62aad98d0b
Change Metadatum::copy return value from long to size_t
2022-03-14 11:47:15 +01:00
Luis Díaz Más
96f7f2e4c5
Convert Exiv2::ErrorCode into an enum class
2022-03-12 16:58:40 +01:00
Luis Díaz Más
c115d4daf7
Merge pull request #2131 from Exiv2/mainCleanups
...
Include what you use + more SPDX identifiers + few other cleanups
2022-03-11 21:02:45 +01:00
Rosen Penev
8dadcdf72a
manual nullptr removals
...
unique_ptr has a bool overload. It's also easier to reason about.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-09 17:12:29 -08:00
Rosen Penev
784cbe2965
manual move conversions
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-09 17:12:24 -08:00
Luis Díaz Más
8b1fe379a1
Removing unused headers thanks to IWYU
2022-03-07 22:25:47 +01:00
Rosen Penev
f0d23eca9b
clang-tidy: add some missing operators
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-06 01:17:12 -08:00
Rosen Penev
133849c394
clang-tidy: remove pointless get()
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-05 16:21:26 -08:00
Rosen Penev
118aa78aa0
clang-tidy: use braced init list
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2022-03-04 15:54:05 -08:00
Luis Díaz Más
b17828b454
Use SPDX for licenses ( #2122 )
...
* Use SPDX identifier in header files
* Use SPDX identifier in rest of source files
* Fix usage of SPDX for files with 2 licenses
* Add global license file
* Fix compilation
2022-03-04 11:44:39 +01:00
Luis Díaz Más
208ec70df8
Fix windows builds
2022-02-27 13:48:21 +01:00
Luis Díaz Más
b9f9d041ea
Several transformations on DataBuf + migration to size_t
...
- Provide begin/end iterators to DataBuf and simplify code
- Adapt test output after last changes
- Replacing long by size_t in value.hpp
- Use size_t in some Photoshop functions
- Remove some static_casts
2022-02-27 09:41:47 +01:00
Luis Díaz Más
aec36f86d7
Replace naked new operators
2022-02-27 09:36:46 +01:00
Kevin Backhouse
256365830a
Replace Metadatum::toLong() with Metadatum::toInt64().
2022-02-18 12:30:33 +00:00
Robin Mills
287744fa12
Merge pull request #2087 from Exiv2/update_canon_tags_2
...
Update canon tags 2
2022-02-15 22:41:37 -08:00
Alex Esseling
23293064bb
work on canon tags
2022-02-14 16:29:42 +01:00
Luis Díaz Más
7933ff401d
Remove dead code around EXV_UNICODE_PATH
2022-02-13 22:49:32 +01:00
Kevin Backhouse
2a3dd2def9
Replace Value::toLong with Value::toInt64. ( #2062 )
...
* Replace Value::toLong with Value::toInt64.
* Fix compiler warning.
* Fix compile error.
* Fix declaration of canonEv
* Fix compiler warning.
* Fix compiler warning.
* Use int64_t for offsets in tiffcomposite_int.cpp
* Fix compiler warning.
* Fix compiler warnings.
* Fix compiler warning.
* Fix compiler warning.
* Fix compiler warning.
* Fix compiler warning.
* Remove static_cast<long int> in TagDetails initializer.
2022-02-12 21:16:18 +00:00
Luis Díaz Más
0f03e77634
Simplify code around UniquePtr(s) & use make_unique over new
2022-02-05 11:02:04 +01:00
Luis Díaz Más
9d8dd86945
Use auto to reduce verbosity around code dealing with iterators
2022-02-05 11:02:03 +01:00
Kevin Backhouse
9ff72e5ca5
Make offset=0 the default parameter.
2021-08-30 12:41:08 +01:00
Kevin Backhouse
c9d0cf3643
Make fields of DataBuf private.
2021-08-29 15:43:10 +01:00
Rosen Penev
e7eddfc2f5
use more emplace_back
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-08-17 19:19:56 -07:00
Kevin Backhouse
69d82ffe01
Defensive coding changes to avoid integer overflow in loop conditions.
2021-07-18 15:02:35 +01:00
Kevin Backhouse
c2b52119d4
Check that findKey didn't return end().
2021-07-05 22:26:09 +02:00
mergify[bot]
1d64f482ff
fix: use vector::at() rather than operator[] (backport #1735 ) ( #1741 )
...
* fix: use vector::at() rather than operator[] (#1735 )
* Regression test for https://github.com/Exiv2/exiv2/issues/1706
* Use vector::at() rather than operator[].
* Print to stderr when exception is caught and EXIV2_DEBUG_MESSAGES is enabled.
* Check that it prints "Bad value" for the date.
(cherry picked from commit f4d3adbf91e6dc4e34aee5bac7b7fd9e127a5c00)
# Conflicts:
# src/value.cpp
* fix merge conflicts from mergify backport
Co-authored-by: Kevin Backhouse <kevinbackhouse@github.com>
Co-authored-by: Christoph Hasse <hassec@users.noreply.github.com>
2021-06-27 09:33:56 +02:00
Rosen Penev
2c57f214c5
clang-tidy: use nullptr
...
Found with modernize-use-nullptr
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-26 08:31:45 +02:00
Rosen Penev
ce47de67b5
use auto in template
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-19 23:09:05 -07:00
Rosen Penev
743da1a564
clang-tidy: use C++ casting
...
Found with google-readability-casting
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-20 07:29:02 +02:00
Rosen Penev
8dbc699858
clang-tidy: add missing explicit
...
Found with google-explicit-constructor
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-19 16:48:44 +02:00
Rosen Penev
b8712188bb
clang-tidy: use auto
...
Found with modernize-use-auto
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-05-17 21:52:03 +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