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

build: remove some warning suppressions #1519

Conversation

federico-sysdig
Copy link
Contributor

@federico-sysdig federico-sysdig commented Nov 28, 2023

What type of PR is this?
/kind cleanup

Any specific area of the project related to this PR?
/area build

Does this PR require a change in the driver versions?
no

What this PR does / why we need it:
The build of this library, when performed with warnings-as-errors enabled, suppresses a number of warnings to be able to get to the end of the build successfully. Some of these suppressions are best avoided and the root cause addressed in order not to have the warnings in the first place. The rationale is that, though more restrictive, compiler warnings are a way to keep code more closely checked and, ultimately, at a higher quality.
FTR, the warnings that the PR re-enables are the following.

  • missing-field-initializers
  • type-limits

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

Signed-off-by: Federico Aponte <federico.aponte@sysdig.com>
@@ -179,7 +179,7 @@ void chisel_view_info::set_sorting_col()
throw sinsp_exception("view format error: more than one sorting column");
}

if((int64_t)m_sortingcol < 0)
if(m_sortingcol < 0)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Here, the type of m_sortingcol was unsigned and the warning was lamenting that the value could never be negative. The type has been converted to signed.

@poiana
Copy link
Contributor

poiana commented Nov 29, 2023

LGTM label has been added.

Git tree hash: 497162b13a6d3f0f1ce7f2b976781d8bfe13168e

@jasondellaluce
Copy link
Contributor

/milestone 0.14.0

@poiana poiana added this to the 0.14.0 milestone Nov 29, 2023
Copy link
Contributor

@FedeDP FedeDP left a comment

Choose a reason for hiding this comment

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

/approve

@poiana
Copy link
Contributor

poiana commented Nov 29, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: FedeDP, federico-sysdig, jasondellaluce

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [FedeDP,jasondellaluce]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@poiana poiana merged commit 8d269a8 into falcosecurity:master Nov 29, 2023
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants