Skip to content

Collection: Include <cstdint>. - #3473

Merged
airween merged 1 commit into
owasp-modsecurity:v3/masterfrom
Gacko:patch-1
Dec 9, 2025
Merged

airween merged 1 commit into
owasp-modsecurity:v3/masterfrom
Gacko:patch-1

Conversation

@Gacko

@Gacko Gacko commented Dec 9, 2025 •

Copy link
Copy Markdown
Contributor

This fixes builds on Alpine v3.23.0 (GCC v15.2.0, musl v1.2.5).

headers/modsecurity/collection/collection.h:x:x: error: 'int32_t' has not been declared
headers/modsecurity/collection/collection.h:x:x: note: 'int32_t' is defined in header '<cstdint>'; this is probably fixable by adding '#include <cstdint>'

This fixes builds on Alpine v3.23.0 (GCC v15.2.0, musl v1.2.5).
Copilot AI review requested due to automatic review settings December 9, 2025 06:51

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a build error on Alpine v3.23.0 (GCC v15.2.0, musl v1.2.5) by adding the missing <cstdint> header include, which is required for the int32_t type used in the Collection class.

  • Adds #include <cstdint> to provide the int32_t type definition

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@sonarqubecloud

sonarqubecloud Bot commented Dec 9, 2025

Copy link
Copy Markdown

@airween

airween commented Dec 9, 2025

Copy link
Copy Markdown
Member

Just a side note: the referenced type (int32_t) is used here.

And one question: is there no other file where it is missing?

@Gacko

Gacko commented Dec 9, 2025

Copy link
Copy Markdown
Contributor Author

And one question: is there no other file where it is missing?

I haven't checked, but we're relying on it in Ingress NGINX and this change made the build of our NGINX base image work: https://github.com/kubernetes/ingress-nginx/blob/main/images/nginx/rootfs/build.sh#L337-L367.

@airween
airween merged commit cebcde3 into owasp-modsecurity:v3/master Dec 9, 2025
56 checks passed
@airween

airween commented Dec 9, 2025

Copy link
Copy Markdown
Member

@Gacko: thanks for this patch!

@Gacko
Gacko deleted the patch-1 branch December 9, 2025 08:51
@airween airween added the 3.x Related to ModSecurity version 3.x label Apr 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.x Related to ModSecurity version 3.x

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants