diff src/com/five_ten_sg/connectbot/service/TerminalMonitor.java @ 100:9204fe526e65

finish setField()
author Carl Byington <carl@five-ten-sg.com>
date Tue, 17 Jun 2014 15:57:18 -0700
parents 01d939969b10
children f0ec55006f31
line wrap: on
line diff
--- a/src/com/five_ten_sg/connectbot/service/TerminalMonitor.java	Tue Jun 17 15:13:41 2014 -0700
+++ b/src/com/five_ten_sg/connectbot/service/TerminalMonitor.java	Tue Jun 17 15:57:18 2014 -0700
@@ -361,12 +361,12 @@
 
     public synchronized void setField(int l, int c, char[] data, int offset) {
         Log.i(TAG, "setField()");
-        byte[] b = new byte[data.length - offset];
+        char[] da = new byte[data.length - offset];
         int i;
-        for (i=0; i<b.length; i++) {
-            b[i] = (byte)(data[i+offset] & 0x00ff);
+        for (i=0; i<da.length; i++) {
+            da[i] = data[i+offset];
         }
-        buffer.write(b);
+        buffer.setField(l, c, da);
     }
 
     public synchronized void getField(int l, int c, int len) {