Fixed invalid arg format (must be []byte) 67/14567/1
authorSebastien Douheret <sebastien.douheret@iot.bzh>
Wed, 20 Jun 2018 21:35:54 +0000 (23:35 +0200)
committerSebastien Douheret <sebastien.douheret@iot.bzh>
Wed, 20 Jun 2018 21:44:38 +0000 (23:44 +0200)
Since changes in xds-server, stdin parameter is now a []byte and no longer
a string (see commit 17812a0a in xds-serve repo).

Change-Id: I3beac02fafb317b404dac250525ac5d4cbe7dd1e
Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
gdb-xds.go

index 9dfb717..54f2270 100644 (file)
@@ -401,7 +401,8 @@ func (g *GdbXds) InferiorRead(f func(timestamp, stdout, stderr string)) {
 
 // Write writes message/string into gdb stdin
 func (g *GdbXds) Write(args ...interface{}) error {
 
 // Write writes message/string into gdb stdin
 func (g *GdbXds) Write(args ...interface{}) error {
-       return g.ioSock.Emit(xaapiv1.ExecInEvent, args...)
+       s := fmt.Sprint(args...)
+       return g.ioSock.Emit(xaapiv1.ExecInEvent, []byte(s))
 }
 
 // SendSignal is used to send a signal to remote process/gdb
 }
 
 // SendSignal is used to send a signal to remote process/gdb