-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: splice: bad file descriptor #73
Comments
show the minimum code that can reproduce the problem |
func (p *Sock5) Start() error {
if p.status == plugins.Running {
return fmt.Errorf("is already running")
}
var options []socks5.Option
options = append(options, socks5.WithLogger(socks5.NewLogger(p.logger)))
if p.username != "" && p.password != "" {
cator := socks5.UserPassAuthenticator{Credentials: socks5.StaticCredentials{p.username: p.password}}
options = append(options, socks5.WithAuthMethods([]socks5.Authenticator{cator}))
}
p.server = socks5.NewServer(options...)
var err error
p.listener, err = net.Listen("tcp", p.address)
if err != nil {
return fmt.Errorf("failed to start: %w", err)
}
p.ctx, p.cancel = context.WithCancel(context.Background())
go func() {
if err := p.server.Serve(p.listener); err != nil {
fmt.Println("stopped:", err)
}
}()
fmt.Println("started")
return nil
} |
this code can't run on my machine |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The sock5 proxy service running on a device with armv7l and linux kernel version 3.10.39 cannot be accessed normally.
The text was updated successfully, but these errors were encountered: