Skip to content

Commit 8d9a4db

Browse files
CdecPGLlontivero
authored andcommitted
Publish IP addreses of NAT device
1 parent d169437 commit 8d9a4db

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

Open.Nat/Pmp/PmpNatDevice.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
// distribute, sublicense, and/or sell copies of the Software, and to
1414
// permit persons to whom the Software is furnished to do so, subject to
1515
// the following conditions:
16-
//
16+
//
1717
// The above copyright notice and this permission notice shall be
1818
// included in all copies or substantial portions of the Software.
19-
//
19+
//
2020
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
2121
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
2222
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND

Open.Nat/Upnp/UpnpNatDevice.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// Authors:
33
// Alan McGovern alan.mcgovern@gmail.com
44
// Ben Motmans <ben.motmans@gmail.com>
5-
// Lucas Ontivero lucasontivero@gmail.com
5+
// Lucas Ontivero lucasontivero@gmail.com
66
//
77
// Copyright (C) 2006 Alan McGovern
88
// Copyright (C) 2007 Ben Motmans
@@ -15,10 +15,10 @@
1515
// distribute, sublicense, and/or sell copies of the Software, and to
1616
// permit persons to whom the Software is furnished to do so, subject to
1717
// the following conditions:
18-
//
18+
//
1919
// The above copyright notice and this permission notice shall be
2020
// included in all copies or substantial portions of the Software.
21-
//
21+
//
2222
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
2323
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
2424
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
@@ -233,7 +233,7 @@ public override async Task DeletePortMapAsync(Mapping mapping)
233233
Guard.IsNotNull(mapping, "mapping");
234234

235235
if (mapping.PrivateIP.Equals(IPAddress.None)) mapping.PrivateIP = DeviceInfo.LocalAddress;
236-
236+
237237
NatDiscoverer.TraceSource.LogInfo("DeletePortMapAsync - Deleteing port mapping {0}", mapping);
238238

239239
try
@@ -246,7 +246,7 @@ await _soapClient
246246
}
247247
catch (MappingException e)
248248
{
249-
if(e.ErrorCode != UpnpConstants.NoSuchEntryInArray) throw;
249+
if(e.ErrorCode != UpnpConstants.NoSuchEntryInArray) throw;
250250
}
251251
}
252252
#endif
@@ -370,7 +370,7 @@ public override async Task<IEnumerable<Mapping>> GetAllMappingsAsync()
370370
|| e.ErrorCode == UpnpConstants.ActionFailed)
371371
{
372372
NatDiscoverer.TraceSource.LogWarn("Router failed with {0}-{1}. No more mappings is assumed.", e.ErrorCode, e.ErrorText);
373-
break;
373+
break;
374374
}
375375
throw;
376376
}
@@ -412,7 +412,7 @@ public override Task<Mapping> GetSpecificMappingAsync(Protocol protocol, int pub
412412
MappingException e = task.Exception.InnerException as MappingException;
413413
if (e != null && e.ErrorCode == UpnpConstants.NoSuchEntryInArray) return null;
414414

415-
// DD-WRT Linux base router (and others probably) fails with 402-InvalidArgument
415+
// DD-WRT Linux base router (and others probably) fails with 402-InvalidArgument
416416
// when no mapping is found in the mappings table
417417
if (e != null && e.ErrorCode == UpnpConstants.InvalidArguments)
418418
{

0 commit comments

Comments
 (0)