Skip to content

Commit

Permalink
Fix IPV6_TRANSPARENT socket option
Browse files Browse the repository at this point in the history
  • Loading branch information
etingof committed Feb 7, 2019
1 parent 4163789 commit f31d892
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ Revision 4.4.9, released 2018-12-XX
-----------------------------------
- Made MIB loader ignoring file and directory access errors
- Fixed crash on MIB load failure in case of directory access error
- Fixed socket transparency option (IPV6_TRANSPARENT)to make IPv6
transparent operation functional

Revision 4.4.8, released 2018-12-30
-----------------------------------
Expand Down
2 changes: 1 addition & 1 deletion pysnmp/carrier/asyncore/dgram/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ def enableTransparent(self, flag=1):
)
if self.socket.family == socket.AF_INET6:
self.socket.setsockopt(
socket.SOL_IPV6, socket.IP_TRANSPARENT, flag
socket.SOL_IPV6, socket.IPV6_TRANSPARENT, flag
)

except socket.error:
Expand Down
3 changes: 2 additions & 1 deletion pysnmp/carrier/sockfix.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
'IP_TRANSPARENT': 19,
'SOL_IPV6': 41,
'IPV6_RECVPKTINFO': 49,
'IPV6_PKTINFO': 50
'IPV6_PKTINFO': 50,
'IPV6_TRANSPARENT': 75
}

for symbol, value in SYMBOLS.items():
Expand Down

0 comments on commit f31d892

Please sign in to comment.