forked from MTSR/mapserver
add guard for #18
This commit is contained in:
parent
56392dfed0
commit
f1986cba99
@ -69,6 +69,13 @@ func (t *WS) ServeHTTP(resp http.ResponseWriter, req *http.Request) {
|
|||||||
|
|
||||||
for {
|
for {
|
||||||
data := <-ch
|
data := <-ch
|
||||||
|
|
||||||
|
if data == nil {
|
||||||
|
//how the hell got a nil reference in here..?!
|
||||||
|
//related issue: #18
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
err := conn.WriteMessage(websocket.TextMessage, data)
|
err := conn.WriteMessage(websocket.TextMessage, data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
break
|
break
|
||||||
|
Loading…
Reference in New Issue
Block a user