We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3b64a4a commit 7571b03Copy full SHA for 7571b03
1 file changed
dnscrypt-proxy/common.go
@@ -180,6 +180,9 @@ func isDigit(b byte) bool { return b >= '0' && b <= '9' }
180
181
// ExtractClientIPStr extracts client IP string from pluginsState based on protocol
182
func ExtractClientIPStr(pluginsState *PluginsState) (string, bool) {
183
+ if pluginsState.clientAddr == nil {
184
+ return "", false
185
+ }
186
switch pluginsState.clientProto {
187
case "udp":
188
return (*pluginsState.clientAddr).(*net.UDPAddr).IP.String(), true
0 commit comments