Compare commits

...

4 Commits

Author SHA1 Message Date
4c6d2b92b6 GIT_SILENT Upgrade ECM and KF version requirements for 5.102.0 release. 2023-01-07 00:28:55 +00:00
05bd9397b3 raw: tweak seek implementation
libraw uses fseek when doing files, which allows seeking past the end
without problems, so do the same, otherwise when we report oss-fuzz
issues they say "give me an example to reproduce" and since our seek
and their seek don't behave the same it's hard to convince them
to fix their code
2022-12-14 23:56:20 +01:00
f4ca3f6783 heif: fix error handling 2022-12-13 11:11:38 +01:00
a30f043e5d heif: rewrite plugin to use only libheif C API
Using C-API instead of C++ libheif API has following advantages:
- More libheif features available (for ex.: strict decoding)
- Linking with static build of libheif is possible
- No need to enable exceptions
2022-12-05 22:43:41 +01:00
4 changed files with 533 additions and 466 deletions

View File

@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.16)
project(KImageFormats)
include(FeatureSummary)
find_package(ECM 5.101.0 NO_MODULE)
find_package(ECM 5.102.0 NO_MODULE)
set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://commits.kde.org/extra-cmake-modules")
feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES)

View File

@ -93,7 +93,6 @@ endif()
if (LibHeif_FOUND)
kimageformats_add_plugin(kimg_heif SOURCES heif.cpp)
target_link_libraries(kimg_heif PkgConfig::LibHeif)
kde_target_enable_exceptions(kimg_heif PRIVATE)
if (QT_MAJOR_VERSION STREQUAL "5")
install(FILES heif.desktop DESTINATION ${KDE_INSTALL_KSERVICESDIR}/qimageioplugins/)

File diff suppressed because it is too large Load Diff

View File

@ -141,7 +141,7 @@ public:
if (whence == SEEK_END) {
pos = size + o;
}
if (pos < 0 || pos > size || m_device->isSequential()) {
if (pos < 0 || m_device->isSequential()) {
return -1;
}
return m_device->seek(pos) ? 0 : -1;