mirror of
https://github.com/buger/goreplay.git
synced 2024-04-21 12:32:02 +00:00
Fix security warning
This commit is contained in:
@@ -21,14 +21,13 @@ func NewDummyOutput() (di *DummyOutput) {
|
||||
// PluginWrite writes message to this plugin
|
||||
func (i *DummyOutput) PluginWrite(msg *plugin.Message) (int, error) {
|
||||
var n, nn int
|
||||
var err error
|
||||
n, err = os.Stdout.Write(msg.Meta)
|
||||
nn, err = os.Stdout.Write(msg.Data)
|
||||
n, _ = os.Stdout.Write(msg.Meta)
|
||||
nn, _ = os.Stdout.Write(msg.Data)
|
||||
n += nn
|
||||
nn, err = os.Stdout.Write(proto.PayloadSeparatorAsBytes)
|
||||
nn, _ = os.Stdout.Write(proto.PayloadSeparatorAsBytes)
|
||||
n += nn
|
||||
|
||||
return n, err
|
||||
return n, nil
|
||||
}
|
||||
|
||||
func (i *DummyOutput) String() string {
|
||||
|
||||
Reference in New Issue
Block a user