format code

pull/56/head
Darien Raymond 2015-12-04 15:49:45 +00:00
parent 1a25931944
commit 3327cb0b80
3 changed files with 6 additions and 6 deletions

View File

@ -56,7 +56,7 @@ func (this *InboundDetourHandler) Start() error {
return nil return nil
}) })
if err != nil { if err != nil {
return err return err
} }
} }
return nil return nil

View File

@ -53,4 +53,4 @@ func TestDokodemoTCP(t *testing.T) {
assert.StringLiteral("Processed: " + payload).Equals(string(response[:nBytes])) assert.StringLiteral("Processed: " + payload).Equals(string(response[:nBytes]))
conn.Close() conn.Close()
} }
} }

View File

@ -1,8 +1,8 @@
package scenarios package scenarios
import ( import (
"os" "os"
"path/filepath" "path/filepath"
_ "github.com/v2ray/v2ray-core/app/router/config/json" _ "github.com/v2ray/v2ray-core/app/router/config/json"
_ "github.com/v2ray/v2ray-core/app/router/rules" _ "github.com/v2ray/v2ray-core/app/router/rules"
@ -25,11 +25,11 @@ import (
) )
func TestFile(filename string) string { func TestFile(filename string) string {
return filepath.Join(os.Getenv("GOPATH"), "src", "github.com", "v2ray", "v2ray-core", "testing", "scenarios", "data", filename) return filepath.Join(os.Getenv("GOPATH"), "src", "github.com", "v2ray", "v2ray-core", "testing", "scenarios", "data", filename)
} }
func InitializeServer(configFile string) error { func InitializeServer(configFile string) error {
config, err := jsonconf.LoadConfig(configFile) config, err := jsonconf.LoadConfig(configFile)
if err != nil { if err != nil {
log.Error("Failed to read config file (%s): %v", configFile, err) log.Error("Failed to read config file (%s): %v", configFile, err)
return err return err