Skip to content

Commit

Permalink
fix version comparison (#446)
Browse files Browse the repository at this point in the history
Fixes a bug that made iOS18 use the old tunnel and fail.
  • Loading branch information
danielpaulus authored Aug 3, 2024
1 parent ca42376 commit 7cc64c8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ios/tunnel/tunnel_api.go
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,8 @@ type manualPairingTunnelStart struct {
}

func (m manualPairingTunnelStart) StartTunnel(ctx context.Context, device ios.DeviceEntry, p PairRecordManager, version *semver.Version, userspaceTUN bool) (Tunnel, error) {
if version.Major() >= 17 && version.Minor() >= 4 {

if version.GreaterThan(semver.MustParse("17.4.0")) {
if userspaceTUN {
tun, err := ConnectUserSpaceTunnelLockdown(device, device.UserspaceTUNPort)
tun.UserspaceTUN = true
Expand Down

0 comments on commit 7cc64c8

Please sign in to comment.