Skip to content

FreeBSD fix for dual-stack and IPv6 QoS#3664

Open
softins wants to merge 2 commits intojamulussoftware:mainfrom
softins:freebsd-fix
Open

FreeBSD fix for dual-stack and IPv6 QoS#3664
softins wants to merge 2 commits intojamulussoftware:mainfrom
softins:freebsd-fix

Conversation

@softins
Copy link
Copy Markdown
Member

@softins softins commented Apr 29, 2026

Short description of changes

Enhances #3622 to fix an issue with running on FreeBSD, which is subtly different from macOS.

CHANGELOG: FreeBSD: make -6 option work properly with both IPv6 and IPv4 peers.

Context: Fixes an issue?

Fixes #3478 and also a crash with #3622 when running with -6 on FreeBSD

Does this change need documentation? What needs to be documented and how?

No, bug fix only

Status of this Pull Request

Tested on both macOS and FreeBSD. No changes to Linux or Windows.

What is missing until this pull request can be merged?

Nothing, but it is important to get this into 3.12.0

Checklist

  • I've verified that this Pull Request follows the general code principles
  • I tested my code and it does what I want
  • My code follows the style guide
  • I waited some time after this Pull Request was opened and all GitHub checks completed without errors.
  • I've filled all the content above

@softins softins added this to the Release 3.12.0 milestone Apr 29, 2026
@softins softins self-assigned this Apr 29, 2026
@softins softins added this to Tracking Apr 29, 2026
@softins softins added the bug Something isn't working label Apr 29, 2026
@github-project-automation github-project-automation Bot moved this to Triage in Tracking Apr 29, 2026
@softins softins requested review from ann0see and pljones April 29, 2026 22:35
@ann0see
Copy link
Copy Markdown
Member

ann0see commented Apr 30, 2026

Ok. Will need to test this on macOS myself then.

Comment thread src/socket.cpp

#if defined( Q_OS_DARWIN )
// sendto_ipv4_with_tos - helper function for macOS to set TOS when sending IPv4 over IPv6 socket
#if defined( Q_OS_BSD4 )
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

And this is guaranteed to always hold for macOS too?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yes, in the header file, Q_OS_DARWIN and Q_OS_BSD4 are set on consecutive lines for Apple.

And my successful tests on Mac confirmed it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

jamulus-server: -6 makes server IPv6 only on FreeBSD

2 participants