浏览代码

format code

v2ray 9 年之前
父节点
当前提交
ea39a6fde6
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      app/dns/nameserver.go
  2. 1 1
      shell/point/inbound_detour_dynamic.go

+ 1 - 1
app/dns/nameserver.go

@@ -149,7 +149,7 @@ func (this *UDPNameServer) BuildQueryA(domain string, id uint16) *alloc.Buffer {
 	msg.Id = id
 	msg.RecursionDesired = true
 	msg.Question = []dns.Question{
-		dns.Question{
+		{
 			Name:   dns.Fqdn(domain),
 			Qtype:  dns.TypeA,
 			Qclass: dns.ClassINET,

+ 1 - 1
shell/point/inbound_detour_dynamic.go

@@ -98,7 +98,7 @@ func (this *InboundDetourHandlerDynamic) refresh() error {
 	this.ich2Recyle = this.ichs
 	newIchs := make([]proxy.InboundHandler, config.Allocation.Concurrency)
 
-	for idx, _ := range newIchs {
+	for idx := range newIchs {
 		err := retry.Timed(5, 100).On(func() error {
 			port := this.pickUnusedPort()
 			ich, err := proxyrepo.CreateInboundHandler(config.Protocol, this.space, config.Settings, &proxy.InboundHandlerMeta{