1// Copyright 2015 The Go Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style 3// license that can be found in the LICENSE file. 4 5package main 6 7import ( 8 "fmt" 9 "net" 10) 11 12func init() { 13 registerInit("NetpollDeadlock", NetpollDeadlockInit) 14 register("NetpollDeadlock", NetpollDeadlock) 15} 16 17func NetpollDeadlockInit() { 18 fmt.Println("dialing") 19 c, err := net.Dial("tcp", "localhost:14356") 20 if err == nil { 21 c.Close() 22 } else { 23 fmt.Println("error: ", err) 24 } 25} 26 27func NetpollDeadlock() { 28 fmt.Println("done") 29} 30