pi-hole / FTL

The Pi-hole FTL engine
https://pi-hole.net
Other
1.34k stars 187 forks source link

Fix pipe transmission #1912

Closed DL6ER closed 3 months ago

DL6ER commented 3 months ago

What does this implement/fix?

Fix pipe transmission from forked dnsmasq process validation changed configurations. This had no real consequences but could lead to missing characters in error messages describing how a new config is invalid (if a user added something invalid). However, as we are testing for this, the CI sometimes automatically retried the jobs most often resulting in a success, eventually.

Example for such an issue: Screenshot from 2024-03-16 09-21-09 (mind the missing initial 'N' of Name does not...)

This PR ensures we properly flush the pipe (by sending 32 bytes of Domestos down the line) before using it so no dirt gets stuck on its way.

Note: Interestingly enough, this has never happened on any of the native builds (not even on the ARM builds on the new ARM64 self-hosted runners) but always only in the emulated buildx environments. Currently, this only affects riscv64.


Related issue or feature (if applicable): N/A

Pull request in docs with documentation (if applicable): N/A


By submitting this pull request, I confirm the following:

  1. I have read and understood the contributors guide, as well as this entire template. I understand which branch to base my commits and Pull Requests against.
  2. I have commented my proposed changes within the code.
  3. I am willing to help maintain this change if there are issues with it later.
  4. It is compatible with the EUPL 1.2 license
  5. I have squashed any insignificant commits. (git rebase)

Checklist:

github-actions[bot] commented 3 months ago

This pull request has conflicts, please resolve those before we can evaluate the pull request.

DL6ER commented 3 months ago

Closing until we're ready to look this again