func (l *logPrefixer) Errorf(format string, args ...interface{}) {
	l.Lock()
	l.log.Errorf(l.prefix(format), args...)
	l.Unlock()
}
Errorf handles error level messages, prefixing them for kodirpc
package kodirpc
import (
	"fmt"
	"os"
	"sync"
)
type LevelledLogger interface {
	Debugf(format string, args ...interface{})
	Infof(format string, args ...interface{})
	Warnf(format string, args ...interface{})
	Errorf(format string, args ...interface{})
	Fatalf(format string, args ...interface{})
	Panicf(format string, args ...interface{})
}
type stubLogger struct{}
func (l *stubLogger) Debugf(format string, args ...interface{}) {}
func (l *stubLogger) Infof(format string, args ...interface{}) {}
func (l *stubLogger) Warnf(format string, args ...interface{}) {}
func (l *stubLogger) Errorf(format string, args ...interface{}) {}
func (l *stubLogger) Fatalf(format string, args ...interface{}) {
	os.Exit(1)
}
func (l *stubLogger) Panicf(format string, args ...interface{}) {
	panic(fmt.Sprintf(format, args...))
}
type logPrefixer struct {
	log LevelledLogger
	sync.Mutex
}
func (l *logPrefixer) Debugf(format string, args ...interface{}) {
	l.Lock()
	l.log.Debugf(l.prefix(format), args...)
	l.Unlock()
}
func (l *logPrefixer) Infof(format string, args ...interface{}) {
	l.Lock()
	l.log.Infof(l.prefix(format), args...)
	l.Unlock()
}
func (l *logPrefixer) Warnf(format string, args ...interface{}) {
	l.Lock()
	l.log.Warnf(l.prefix(format), args...)
	l.Unlock()
}