1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Split on spaces or commas properly

This commit is contained in:
Evan Phoenix 2016-01-11 09:14:56 -08:00
parent 3c8763669b
commit 246e71840e

View file

@ -309,7 +309,7 @@ module Puma
return @peerip if @peerip
if @remote_addr_header
hdr = (@env[@remote_addr_header] || LOCALHOST_ADDR).split(/\s,/).first
hdr = (@env[@remote_addr_header] || LOCALHOST_ADDR).split(/[\s,]/).first
@peerip = hdr
return hdr
end