Commit 95f588d
committed
fix(network): filter virtual network interfaces correctly on Windows
Fix data migration failure when multiple network adapters exist, including
virtual adapters like VMware Network Adapter VMnet1. On Windows, virtual
adapter names in QNetworkInterface::name() are GUIDs, not "vmnet*", so the
previous filter failed to exclude them, causing the app to select the wrong
IP address (e.g., 192.168.199.1 instead of the real WLAN IP 192.168.43.204).
Changes:
- Add isVirtualInterface() helper to check both name() and humanReadableName()
- Linux: filter virbr*, vmnet*, docker*, veth*, br- prefixes
- Windows: filter VMware, VirtualBox, Hyper-V, Virtual Ethernet, vEthernet, Bluetooth
This ensures the sender advertises the correct IP address and the web server
binds to a reachable network interface, preventing 0B file transfers.1 parent 930da60 commit 95f588d
2 files changed
Lines changed: 45 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
27 | 48 | | |
28 | 49 | | |
29 | 50 | | |
| |||
38 | 59 | | |
39 | 60 | | |
40 | 61 | | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
| 62 | + | |
45 | 63 | | |
46 | 64 | | |
47 | 65 | | |
| |||
52 | 70 | | |
53 | 71 | | |
54 | 72 | | |
55 | | - | |
| 73 | + | |
56 | 74 | | |
57 | 75 | | |
58 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
26 | 47 | | |
27 | 48 | | |
28 | 49 | | |
| |||
35 | 56 | | |
36 | 57 | | |
37 | 58 | | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
| 59 | + | |
42 | 60 | | |
43 | 61 | | |
44 | 62 | | |
| |||
0 commit comments