tjjh89017 / stunmesh-go

GNU General Public License v2.0
35 stars 3 forks source link

Fix defer conn.Close() not called after log.Fatal() #10

Closed elct9620 closed 3 months ago

elct9620 commented 3 months ago

The log.Fatal() will use os.Exit(1) and the defer never be called. To ensure the connection is closed, use log.Panic() instead.