diff --git a/business/jxstore/cms/temp.go b/business/jxstore/cms/temp.go index 08e7f2579..7c393e557 100644 --- a/business/jxstore/cms/temp.go +++ b/business/jxstore/cms/temp.go @@ -1,11 +1,8 @@ package cms import ( - "bufio" "fmt" "net" - "os" - "strings" ) func TestTemp() { @@ -15,21 +12,9 @@ func TestTemp() { return } defer conn.Close() // 关闭连接 - //客户端可以发送单行数据 - reader := bufio.NewReader(os.Stdin) for { - input, err := reader.ReadString('\n') - if err != nil { - fmt.Println("readstring err=", err) - } - inputInfo := strings.Trim(input, "\r\n") - //fmt.Println(inputInfo) - if strings.ToUpper(inputInfo) == "Q" { // 如果输入q就退出 - return - } - //将line发送给服务器 - _, err = conn.Write([]byte(inputInfo)) + _, err = conn.Write([]byte("aaaa")) if err != nil { fmt.Println("conn.write err=", err) }