Skip to content

Commit

Permalink
Improve Ractor-compliance
Browse files Browse the repository at this point in the history
  • Loading branch information
rm155 authored and hsbt committed Sep 8, 2022
1 parent 334aa98 commit 7346172
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/ipaddr.rb
Expand Up @@ -47,7 +47,7 @@ class IPAddr
# 128 bit mask for IPv6
IN6MASK = 0xffffffffffffffffffffffffffffffff
# Format string for IPv6
IN6FORMAT = (["%.4x"] * 8).join(':')
IN6FORMAT = (["%.4x"] * 8).join(':').freeze

# Regexp _internally_ used for parsing IPv4 address.
RE_IPV4ADDRLIKE = %r{
Expand Down Expand Up @@ -736,7 +736,7 @@ def _to_string(addr)
unless Socket.const_defined? :AF_INET6
class Socket < BasicSocket
# IPv6 protocol family
AF_INET6 = Object.new
AF_INET6 = Object.new.freeze
end

class << IPSocket
Expand Down

0 comments on commit 7346172

Please sign in to comment.