core/vm: fixed printable characters using unicode instead

This commit is contained in:
obscuren
2015-06-12 11:18:17 +02:00
parent e2c2d8e15e
commit 02d629af8f
2 changed files with 2 additions and 6 deletions

View File

@ -3,7 +3,7 @@ package vm
import (
"fmt"
"os"
"unicode/utf8"
"unicode"
"github.com/ethereum/go-ethereum/common"
)
@ -27,7 +27,7 @@ func StdErrFormat(logs []StructLog) {
for _, r := range data {
if r == 0 {
str += "."
} else if utf8.ValidRune(rune(r)) {
} else if unicode.IsPrint(rune(r)) {
str += fmt.Sprintf("%s", string(r))
} else {
str += "?"