pkg/util/iptables: use buf.String() instead of string(buf.Bytes())
Signed-off-by: TommyStarK <thomasmilox@gmail.com>
This commit is contained in:
@@ -483,6 +483,11 @@ func (buf *LineBuffer) Bytes() []byte {
|
||||
return buf.b.Bytes()
|
||||
}
|
||||
|
||||
// String returns the contents of buf as a string
|
||||
func (buf *LineBuffer) String() string {
|
||||
return buf.b.String()
|
||||
}
|
||||
|
||||
// Lines returns the number of lines in buf. Note that more precisely, this returns the
|
||||
// number of times Write() or WriteBytes() was called; it assumes that you never wrote
|
||||
// any newlines to the buffer yourself.
|
||||
|
Reference in New Issue
Block a user