master
Jordan Orelli 8 years ago
parent d55cd19ccb
commit 3073b50948

@ -19,9 +19,9 @@ type dataGram struct {
func (g dataGram) String() string { func (g dataGram) String() string {
if len(g.body) > 30 { if len(g.body) > 30 {
return fmt.Sprintf("{dataGram cmd: %v tick: %v size: %d body: %q...}", g.cmd, g.tick, len(g.body), g.body[:27]) return fmt.Sprintf("{dataGram cmd: %v tick: %v size: %d body: %x...}", g.cmd, g.tick, len(g.body), g.body[:27])
} }
return fmt.Sprintf("{dataGram cmd: %v tick: %v size: %d body: %q}", g.cmd, g.tick, len(g.body), g.body) return fmt.Sprintf("{dataGram cmd: %v tick: %v size: %d body: %x}", g.cmd, g.tick, len(g.body), g.body)
} }
func (g *dataGram) check(dump bool) error { func (g *dataGram) check(dump bool) error {

@ -11,8 +11,8 @@ type entity struct {
} }
func (e entity) String() string { func (e entity) String() string {
if len(e.body) < 32 { if len(e.body) < 30 {
return fmt.Sprintf("{entity type: %d size: %d data: %x}", e.t, e.size, e.body) return fmt.Sprintf("{entity type: %d size: %d data: %x}", e.t, e.size, e.body)
} }
return fmt.Sprintf("{entity type: %d size: %d data: %x...}", e.t, e.size, e.body[:32]) return fmt.Sprintf("{entity type: %d size: %d data: %x...}", e.t, e.size, e.body[:27])
} }

Loading…
Cancel
Save