blob: 37edaff5a578a0cd7c5f2fc09c459a50044cde23 [file] [log] [blame]
khenaidooffe076b2019-01-15 16:08:08 -05001// Copyright 2016 The Gorilla WebSocket 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
5// +build !go1.8
6
7package websocket
8
9func (c *Conn) writeBufs(bufs ...[]byte) error {
10 for _, buf := range bufs {
11 if len(buf) > 0 {
12 if _, err := c.conn.Write(buf); err != nil {
13 return err
14 }
15 }
16 }
17 return nil
18}