Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Coverity fixes #60555

Merged
merged 4 commits into from
Feb 12, 2025
Merged

Coverity fixes #60555

merged 4 commits into from
Feb 12, 2025

Conversation

nyalldawson
Copy link
Collaborator

No description provided.

The warning is a false positive, since we were already checking
that the optional has a value before accessing it. But we can
avoid the exception altogether (and gain some performance) by
using the std::optional dereference operator, which DOES not
throw and which relies on the previous has_value check to avoid
undefined behavior.
@github-actions github-actions bot added this to the 3.42.0 milestone Feb 12, 2025
Copy link

github-actions bot commented Feb 12, 2025

🪟 Windows builds

Download Windows builds of this PR for testing.
Debug symbols for this build are available here.
(Built from commit e3762c5)

🪟 Windows Qt6 builds

Download Windows Qt6 builds of this PR for testing.
(Built from commit e3762c5)

@troopa81 troopa81 merged commit c1f2f2e into qgis:master Feb 12, 2025
39 checks passed
@qgis-bot
Copy link
Collaborator

The backport to release-3_40 failed:

The process '/usr/bin/git' failed with exit code 1
stderr
error: could not apply 73525ed182a... Initialize members
hint: After resolving the conflicts, mark them with
hint: "git add/rm <pathspec>", then run
hint: "git cherry-pick --continue".
hint: You can instead skip this commit with "git cherry-pick --skip".
hint: To abort and get back to the state before "git cherry-pick",
hint: run "git cherry-pick --abort".
hint: Disable this message with "git config set advice.mergeConflict false"

stdout
CONFLICT (modify/delete): src/core/pointcloud/qgspointcloudlayerundocommand.h deleted in HEAD and modified in 73525ed182a (Initialize members).  Version 73525ed182a (Initialize members) of src/core/pointcloud/qgspointcloudlayerundocommand.h left in tree.

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-release-3_40 release-3_40
# Navigate to the new working tree
cd .worktrees/backport-release-3_40
# Create a new branch
git switch --create backport-60555-to-release-3_40
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick 73525ed182aea6926c6a32a33fb4b091c8cc0331,bcdedb4fcf4387e317d1eb173de8ff6946e48281,8f170a683075285a58aa49956c633221ac56566f,e3762c5f6e46b408f4a06319734bbcb6e4fcf111
# Push it to GitHub
git push --set-upstream origin backport-60555-to-release-3_40
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-release-3_40

Then, create a pull request where the base branch is release-3_40 and the compare/head branch is backport-60555-to-release-3_40.

@qgis-bot qgis-bot added the failed backport The automated backport attempt failed, needs a manual backport label Feb 12, 2025
@nyalldawson nyalldawson deleted the coverity branch February 12, 2025 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport release-3_40 failed backport The automated backport attempt failed, needs a manual backport
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants