Skip to content

Don't forward declare static functions in sendmail.h #17684

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

Merged
merged 1 commit into from
Feb 3, 2025

Conversation

cmb69
Copy link
Member

@cmb69 cmb69 commented Feb 3, 2025

sendmail.h is not only included by sendmail.c, but also by php_win32_globals.h, because that header uses some of the defined macros. However, the forward declarations of the static functions are not needed anywhere else than in sendmail.c, and Clang warns about the unused functions elsewhere (-Wunused-function). Thus we move the forward declarations to sendmail.c.

sendmail.h is not only included by sendmail.c, but also by
php_win32_globals.h, because that header uses some of the defined
macros.  However, the forward declarations of the static functions are
not needed anywhere else than in sendmail.c, and Clang warns about the
unused functions elsewhere (`-Wunused-function`).  Thus we move the
forward declarations to sendmail.c.
@cmb69 cmb69 removed the ABI break label Feb 3, 2025
@cmb69 cmb69 marked this pull request as ready for review February 3, 2025 15:50
@cmb69 cmb69 merged commit 4e6a3ce into php:master Feb 3, 2025
9 checks passed
@cmb69 cmb69 deleted the cmb/sendmail-static-forward branch February 3, 2025 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants