Skip to content

Commit

Permalink
MapToIPv4 before IPAddress convert to int
Browse files Browse the repository at this point in the history
  • Loading branch information
gisellevonbingen committed Aug 9, 2023
1 parent 19f124e commit 8c4232c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Giselle.Net.EtherNetIP/IPAddressUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public static IPAddress ToIPv4Address(this int address, bool isBigEndian = true)

public static int ToIPv4Address(this IPAddress address, bool isBigEndian = true)
{
var bytes = address.GetAddressBytes();
var bytes = address.MapToIPv4().GetAddressBytes();
int value = 0;

if (isBigEndian == true)
Expand Down

0 comments on commit 8c4232c

Please sign in to comment.