Skip to content
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]客戶端崩潰 #357

Closed
ring66066 opened this issue Jun 2, 2021 · 3 comments · Fixed by #358
Closed

[BUG]客戶端崩潰 #357

ring66066 opened this issue Jun 2, 2021 · 3 comments · Fixed by #358

Comments

@ring66066
Copy link

系統:
Architecture ARMv7 Processor rev 1 (v7l)
Firmware Version OpenWrt 19.07.7 r11306-c4a6851c72

開啟router的情況下直連訪問不會報錯,使用代理則崩潰:

[INFO] 2021/06/02 01:37:34 trojan-go v0.10.3 initializing
panic: unaligned 64-bit atomic operation

goroutine 16 [running]:
runtime/internal/atomic.panicUnaligned()
runtime/internal/atomic/unaligned.go:8 +0x24
runtime/internal/atomic.Xadd64(0x2d8f71c, 0x8, 0x0, 0x8, 0x8)
runtime/internal/atomic/asm_arm.s:233 +0x14
github.com/p4gefau1t/trojan-go/tunnel/trojan.(*OutboundConn).Read(0x2d8f710, 0x2d08000, 0x8, 0x8, 0x1a054, 0xb66dd0, 0x0)
github.com/p4gefau1t/trojan-go/tunnel/trojan/client.go:83 +0x9c
io.ReadAtLeast(0xa6c86010, 0x2d9e7c0, 0x2d08000, 0x8, 0x8, 0x8, 0x0, 0x0, 0x0)
io/io.go:328 +0x6c
io.ReadFull(...)
io/io.go:347
github.com/xtaci/smux.(*Session).recvLoop(0x2bf3360)
github.com/xtaci/[email protected]/session.go:320 +0x128
created by github.com/xtaci/smux.newSession
github.com/xtaci/[email protected]/session.go:105 +0x240

客戶端配置:
{
"run_type": "client",
"local_addr": "127.0.0.1",
"local_port": 1081,
"remote_addr": "",
"remote_port": 443,
"log_level": 1,
"log_file": "/var/log/trojan-go-error.log",
"password": [
""
],
"ssl": {
"sni": ""
},
"mux": {
"enabled": true,
"concurrency": 8,
"idle_timeout": 60
},
"router": {
"enabled": true,
"bypass": [
"geoip:cn",
"geoip:private",
"geosite:cn",
"geosite:private"
],
"block": [
"geosite:category-ads"
],
"proxy": [
"geosite:geolocation-!cn"
],
"default_policy": "proxy",
"domain_strategy": "as_is",
"geoip": "/mnt/sda1/bin/trojan-go/geoip.dat",
"geosite": "/mnt/sda1/bin/trojan-go/geosite.dat"
},
"websocket": {
"enabled": true,
"path": "",
"host": ""
},
"shadowsocks": {
"enabled": true,
"method": "CHACHA20-IETF-POLY1305",
"password": ""
}
}

版本v0.10.3崩潰 ,v0.10.0正常

@Loyalsoldier
Copy link
Collaborator

尝试一下使用 Go v1.16.3 编译 Trojan-Go v0.10.3,再运行起来看看会不会崩溃

@ring66066
Copy link
Author

編譯環境:go version go1.16.4 windows/amd64:

panic: unaligned 64-bit atomic operation

goroutine 26 [running]:
runtime/internal/atomic.panicUnaligned()
C:/Program Files/Go/src/runtime/internal/atomic/unaligned.go:8 +0x24
runtime/internal/atomic.Xadd64(0x27b371c, 0x8, 0x0, 0x8, 0x8)
C:/Program Files/Go/src/runtime/internal/atomic/asm_arm.s:233 +0x14
github.com/p4gefau1t/trojan-go/tunnel/trojan.(*OutboundConn).Read(0x27b3710, 0x2858bd8, 0x8, 0x8, 0x1a054, 0xb76dd0, 0x0)
C:/Users/costom/Desktop/trojan-go-0.10.3/tunnel/trojan/client.go:83 +0x9c
io.ReadAtLeast(0xa6c23960, 0x28567f0, 0x2858bd8, 0x8, 0x8, 0x8, 0x0, 0x0, 0x0)
C:/Program Files/Go/src/io/io.go:328 +0x6c
io.ReadFull(...)
C:/Program Files/Go/src/io/io.go:347
github.com/xtaci/smux.(*Session).recvLoop(0x271b360)
C:/Users/costom/go/pkg/mod/github.com/xtaci/[email protected]/session.go:320 +0x128
created by github.com/xtaci/smux.newSession
C:/Users/costom/go/pkg/mod/github.com/xtaci/[email protected]/session.go:105 +0x240

@Loyalsoldier
Copy link
Collaborator

试一试这个 PR: #358

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants