From 90c1dbb8b9b597493ad07d02604632d2fc741d5f Mon Sep 17 00:00:00 2001 From: xiaoyifang <105986+xiaoyifang@users.noreply.github.com> Date: Mon, 5 Dec 2022 20:55:52 +0800 Subject: [PATCH 1/4] action: sonar check (#243) * action:sonar check Co-authored-by: xiaoyifang --- .github/workflows/build.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3de5a35d..3140481c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,5 +1,9 @@ name: SonarCloud +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true on: + workflow_dispatch: push: branches: - dev @@ -48,8 +52,8 @@ jobs: uses: SonarSource/sonarcloud-github-c-cpp@v1 - name: Run build-wrapper run: | - cmake . - build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} cmake --build . + qmake CONFIG+=release CONFIG+=no_extra_tiff_handler CONFIG+=zim_support CONFIG+=chinese_conversion_support + build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} make -j8 - name: Run sonar-scanner env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 55d13305caa40e7816eae73b32684c3a4452d89b Mon Sep 17 00:00:00 2001 From: xiaoyifang <105986+xiaoyifang@users.noreply.github.com> Date: Wed, 7 Dec 2022 09:09:45 +0800 Subject: [PATCH 2/4] Update readme.txt --- icons/readme.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/icons/readme.txt b/icons/readme.txt index 873d578e..e06aa69e 100644 --- a/icons/readme.txt +++ b/icons/readme.txt @@ -65,4 +65,6 @@ reload.png https://iconarchive.com/show/oxygen-icons-by-oxygen-icons.org/Actions advanced.png https://icons.iconarchive.com/icons/oxygen-icons.org/oxygen/128/Actions-system-run-icon.png sources.png https://icons.iconarchive.com/icons/oxygen-icons.org/oxygen/128/Apps-plasma-icon.png +book.svg https://github.com/johnfactotum/foliate + From f8db78be34397a2cf5bc0a210b3fbcafe0d2563b Mon Sep 17 00:00:00 2001 From: xiaoyifang <105986+xiaoyifang@users.noreply.github.com> Date: Wed, 7 Dec 2022 09:16:20 +0800 Subject: [PATCH 3/4] fixed issue #246, security warning. --- dictzip.c | 1 - 1 file changed, 1 deletion(-) diff --git a/dictzip.c b/dictzip.c index 1ac3c62d..bccde99e 100644 --- a/dictzip.c +++ b/dictzip.c @@ -575,7 +575,6 @@ void dict_data_close( dictData *header ) xfree (header -> cache [i].inBuffer); } - memset( header, 0, sizeof( struct dictData ) ); xfree( header ); } From 5757fff5a62b493916e6d1b378916ee66dc1c8ef Mon Sep 17 00:00:00 2001 From: Xiao YiFang Date: Wed, 7 Dec 2022 20:20:57 +0800 Subject: [PATCH 4/4] fix: qprocess error signal is changed to errorOccurred() fixed #238 --- externalviewer.cc | 2 +- programs.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/externalviewer.cc b/externalviewer.cc index ac76003c..bd84b4bb 100644 --- a/externalviewer.cc +++ b/externalviewer.cc @@ -35,7 +35,7 @@ void ExternalViewer::start() { connect( &viewer, SIGNAL( finished( int, QProcess::ExitStatus ) ), this, SLOT( deleteLater() ) ); - connect( &viewer, SIGNAL( error( QProcess::ProcessError ) ), + connect( &viewer, SIGNAL( errorOccurred( QProcess::ProcessError ) ), this, SLOT( deleteLater() ) ); QStringList args = parseCommandLine( viewerCmdLine ); diff --git a/programs.cc b/programs.cc index 3085cd3b..a2e9111f 100644 --- a/programs.cc +++ b/programs.cc @@ -141,7 +141,7 @@ RunInstance::RunInstance(): process( this ) connect( this, SIGNAL(processFinished()), this, SLOT(handleProcessFinished()), Qt::QueuedConnection ); connect( &process, SIGNAL(finished(int)), this, SIGNAL(processFinished())); - connect( &process, SIGNAL(error(QProcess::ProcessError)), this, + connect( &process, SIGNAL(errorOccurred(QProcess::ProcessError)), this, SIGNAL(processFinished()) ); }