Skip to content

Bugfix: Number of OpenMP threads was not validated, ...#4863

Merged
mvieth merged 1 commit intoPointCloudLibrary:masterfrom
MK-3PP:master
Jul 27, 2021
Merged

Bugfix: Number of OpenMP threads was not validated, ...#4863
mvieth merged 1 commit intoPointCloudLibrary:masterfrom
MK-3PP:master

Conversation

@MK-3PP
Copy link
Copy Markdown

@MK-3PP MK-3PP commented Jul 26, 2021

causing OpenMP User Error 1001: argument to num_threads clause must be positive" if number of threads was 0. (Issue #4860)

According to documentation, 0 should be "auto".
Added input validation to getBoundaryPoints method, treating 0 as "auto" (example taken from normal_3d_omp.hpp). Method is also used in class constructor to validate initialization value of the threads_ member, adhering to the DRY principle.

…ser Error 1001: argument to num_threads clause must be positive" if number of threads was 0.

According to documentation, 0 should be "auto".
Added input validation to getBoundaryPoints method, treating 0 as "auto" (example taken from normal_3d_omp.hpp). Method is also used in class constructor to validate initialization value of the threads_ member, adhering to the DRY principle.
Copy link
Copy Markdown
Member

@kunaltyagi kunaltyagi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kunaltyagi kunaltyagi added changelog: fix Meta-information for changelog generation module: keypoints labels Jul 27, 2021
@kunaltyagi kunaltyagi linked an issue Jul 27, 2021 that may be closed by this pull request
@kunaltyagi kunaltyagi added this to the pcl-1.12.1 milestone Jul 27, 2021
Copy link
Copy Markdown
Member

@mvieth mvieth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@mvieth mvieth merged commit fffde55 into PointCloudLibrary:master Jul 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog: fix Meta-information for changelog generation module: keypoints

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ISSKeypoint3D::compute crashes with OMP and 0 threads.

3 participants