Commit Graph

302 Commits

Author SHA1 Message Date
Shadowghost
c042f20224 Merge branch 'master' into network-rewrite 2023-05-11 15:41:39 +02:00
Cody Robibero
e1a30a4aef
Merge pull request #8598 from Neuheit/ipv4fallback 2023-05-11 07:12:34 -06:00
Shadowghost
a5bfeb28aa Apply review suggestions 2023-02-20 21:51:15 +01:00
Shadowghost
a5f16136eb Apply review suggestions 2023-02-20 16:58:22 +01:00
Bond_009
24a7e210c3 Optimize tryparse
* Don't check for null before
* Don't try different formats when not needed (NumberFormat.Integer is the fast path)
2023-02-19 16:52:29 +01:00
Shadowghost
20fd05b050 Consistently write IP in upercase 2023-02-17 19:27:36 +01:00
Shadowghost
42498194d9 Replace ISocket and UdpSocket, fix DLNA and SSDP binding and discovery 2023-02-17 17:39:11 +01:00
Shadowghost
4eba16c672 Apply review suggestions 2023-02-15 22:34:44 +01:00
Shadowghost
1cc7572445 Apply review suggestions 2023-02-15 11:31:47 +01:00
Bond-009
36b7157589
Fix #9300 (#9312) 2023-02-14 12:08:52 -07:00
Shadowghost
414eb45899 Merge branch 'master' into network-rewrite 2023-01-24 23:48:47 +01:00
Patrick Barron
5d1b5d257f Remove CustomHeaderNames 2023-01-20 18:28:18 -05:00
Shadowghost
3f6354cdb8 Fix .NET 7 compatibility 2022-12-07 17:41:32 +01:00
Bond_009
52194f56b5 Replace != null with is not null 2022-12-05 15:01:13 +01:00
Bond_009
c7d50d640e Replace == null with is null 2022-12-05 15:00:20 +01:00
Neuheit
c9a387943f Add IPv4 fallback from IPv6 failure.
Co-authored-by: BaronGreenback <jimcartlidge@yahoo.co.uk>
2022-10-20 16:17:56 -04:00
Shadowghost
f6d6f0367b Properly handle IPs with subnetmasks 2022-10-17 15:51:09 +02:00
Shadowghost
26d79a5ce3 Properly name some bind address functions, cleanup logging 2022-10-16 10:22:11 +02:00
Shadowghost
87d0158a4a Fix autodiscovery 2022-10-15 17:27:37 +02:00
Shadowghost
4aec41752f Apply review suggestions 2022-10-14 10:25:57 +02:00
Shadowghost
7b90fcd053 Merge branch 'master' into network-rewrite 2022-10-07 09:16:02 +02:00
Bond_009
a9a5fcde81 Use ArgumentNullException.ThrowIfNull helper method
Did a simple search/replace on the whole repo (except the RSSDP project)
This reduces LOC and should improve performance (methods containing a throw statement don't get inlined)

```
if \((\w+) == null\)
\s+\{
\s+throw new ArgumentNullException\((.*)\);
\s+\}
```

```
ArgumentNullException.ThrowIfNull($1);
```
2022-10-06 20:21:23 +02:00
Shadowghost
4fc52a840c Merge branch 'master' into network-rewrite 2022-10-01 19:59:00 +02:00
Bond-009
33611614ed
Merge pull request #7433 from Bond-009/ssdphttpclient 2022-08-22 17:52:19 +02:00
Shadowghost
59a86568d9 Cleanup and fixes 2022-07-21 22:09:54 +02:00
Shadowghost
2d3a16ad0f Simplify code 2022-07-20 21:19:35 +02:00
Shadowghost
2281b8c997 Move away from using Collection, simplify code, add proper ordering 2022-07-20 14:29:30 +02:00
Shadowghost
a492082f4e Apply review suggestions and fix build 2022-07-20 11:47:48 +02:00
Shadowghost
64ffd5fd95 Move subnet parser to NetworkExtensions 2022-07-20 09:45:57 +02:00
Shadowghost
997aa3f1e7 Fix build 2022-07-19 21:53:10 +02:00
Shadowghost
066db8ac7f Migrate NetworkManager and Tests to native .NET IP objects 2022-07-19 21:28:04 +02:00
Cody Robibero
94a69c8a8b Merge pull request #7549 from cvium/fix_isinlocalnetwork
(cherry picked from commit bdb85aeecf)
Signed-off-by: crobibero <cody@robibe.ro>
2022-04-07 12:54:58 -04:00
Bond_009
cafeedcadf Rework SsdpHttpClient 2022-03-08 23:00:43 +01:00
Cody Robibero
7bfc6b5679 Remove more warnings 2021-12-27 07:38:06 -07:00
Bond_009
4c1286fd24 Address comment 2021-08-12 21:38:54 +02:00
Bond_009
60053c7f3d Fix log messages 2021-08-04 18:49:54 +02:00
Bond_009
442dc10aac ApiServiceCollectionExtensions.AddProxyAddresses: Add more tests 2021-08-04 18:43:26 +02:00
Bond_009
915141f196 Fix some warnings 2021-07-11 22:51:36 +02:00
Bond-009
a4a3f598af
Merge pull request #5982 from Bond-009/nullable 2021-05-06 23:33:41 +02:00
BaronGreenback
2e98de9062
Code Clean up: Convert to null-coalescing operator ?? (#5845)
Co-authored-by: Cody Robibero <cody@robibe.ro>
Co-authored-by: Patrick Barron <18354464+barronpm@users.noreply.github.com>
2021-05-05 13:51:14 +02:00
Bond_009
91c2a57b28 Enable nullable reference types for MediaBrowser.Common 2021-05-05 12:57:01 +02:00
Bond_009
500c2e5224 Switch from HttpClientHandler to SocketsHttpHandler
SocketsHttpHandler is the default for .Net Core 2.1 and newer

Set RequestHeaderEncoding to UTF-8 by default
2021-04-19 22:37:24 +02:00
BaronGreenback
bc1cc2d04a Remove unused using directives 2021-04-17 11:37:55 +01:00
BaronGreenback
0b774eac12
Enables the ability to bind to loopback address. (#5773) 2021-04-14 11:26:05 +02:00
Bond-009
1361ccd9ea
Merge pull request #5763 from Bond-009/ipobjects
Minor improvements to IPObjects
2021-04-11 23:31:03 +02:00
Joshua M. Boniface
19e7ebb279
Merge pull request #5416 from BaronGreenback/SubnetOverlappFix 2021-04-11 13:29:00 -04:00
Bond_009
be9cb7af2c Minor improvements to IPObjects 2021-04-10 22:42:09 +02:00
BaronGreenback
5d16d1f66d
Merge branch 'master' into RemoteAccessFix 2021-03-22 17:05:44 +00:00
BaronGreenback
4c7680e186 Merge remote-tracking branch 'upstream/master' into SubnetOverlappFix 2021-03-14 18:40:44 +00:00
BaronGreenback
6087831aa6 Fixed selection of correct interface ip 2021-03-14 17:30:25 +00:00