GithubHelp home page GithubHelp logo

Comments (4)

sndnvaps avatar sndnvaps commented on July 19, 2024

你直接改一改源代码啊,再编译它。
加个,你得把你运行的命令写一写,不然鬼知道你是怎样测试导致问题的啊。

from proxypool.

liliang8858 avatar liliang8858 commented on July 19, 2024

panic: runtime error: invalid memory address or nil pointer dereference

`# ./proxy
2019/12/30 11:40:57 [TRACE] Log path:
2019/12/30 11:40:57 [TRACE] Log Mode: File (Info)
2019/12/30 11:40:57 [ INFO] ProxyPool
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0xd0 pc=0x817006]

goroutine 1 [running]:
github.com/go-xorm/xorm.(*Session).Init(0xc00018c700)
/usr/local/gopath/pkg/mod/github.com/go-xorm/[email protected]/session.go:94 +0x1e6
github.com/go-xorm/xorm.(*Engine).NewSession(...)
/usr/local/gopath/pkg/mod/github.com/go-xorm/[email protected]/engine.go:317
github.com/go-xorm/xorm.(*Engine).Where(0x0, 0xa198e0, 0xbb0100, 0xc0000f2c40, 0x1, 0x1, 0xc00013def8)
/usr/local/gopath/pkg/mod/github.com/go-xorm/[email protected]/engine.go:601 +0x56
github.com/henson/proxypool/pkg/models.countIps(0x8)
/usr/local/gopath/pkg/mod/github.com/henson/[email protected]/pkg/models/ip.go:46 +0x8a
github.com/henson/proxypool/pkg/models.CountIPs(...)
/usr/local/gopath/pkg/mod/github.com/henson/[email protected]/pkg/models/ip.go:52
main.main()
/usr/local/proxy/proxypool/main.go:45 +0xdd`

from proxypool.

liliang8858 avatar liliang8858 commented on July 19, 2024

再次允许成功,但是访问一次既异常:

2019/12/30 11:49:13 http: panic serving 115.236.179.140:60598: runtime error: invalid memory address or nil pointer dereference
goroutine 300 [running]:
net/http.(*conn).serve.func1(0xc000641680)
/usr/local/go/src/net/http/server.go:1767 +0x139
panic(0xa4cd60, 0x1163270)
/usr/local/go/src/runtime/panic.go:679 +0x1b2
github.com/henson/proxypool/pkg/storage.ProxyRandom(0xa81420)
/usr/local/gopath/pkg/mod/github.com/henson/[email protected]/pkg/storage/filter.go:90 +0xc6
github.com/henson/proxypool/api.ProxyHandler(0xbc7660, 0xc0006128c0, 0xc000349c00)
/usr/local/gopath/pkg/mod/github.com/henson/[email protected]/api/api.go:29 +0x118
net/http.HandlerFunc.ServeHTTP(0xb1caa0, 0xbc7660, 0xc0006128c0, 0xc000349c00)
/usr/local/go/src/net/http/server.go:2007 +0x44
net/http.(*ServeMux).ServeHTTP(0xc000063d00, 0xbc7660, 0xc0006128c0, 0xc000349c00)
/usr/local/go/src/net/http/server.go:2387 +0x1bd
net/http.serverHandler.ServeHTTP(0xc0000d82a0, 0xbc7660, 0xc0006128c0, 0xc000349c00)
/usr/local/go/src/net/http/server.go:2802 +0xa4
net/http.(*conn).serve(0xc000641680, 0xbc8ca0, 0xc000596c00)
/usr/local/go/src/net/http/server.go:1890 +0x875
created by net/http.(*Server).Serve
/usr/local/go/src/net/http/server.go:2927 +0x38e

from proxypool.

sndnvaps avatar sndnvaps commented on July 19, 2024

你得说明一下,什么操作导致的panic啊。。
你这光说错误,我怎么知道你的原因呢。。
如果是运行的时候报错,建议换一个版本的go
我使用的是版本是 go 1.13.1 win/386
@liliang8858

from proxypool.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.