public synchronized void
   write(String fmt, Object... args) throws SJTerminateError {
      try {
         otmp.reset();
         
         byte[] tail = null;
         int tail_count = 0;
         int len = fmt.length();
         int acnt = 0;
         for (int a = 0; a<len;) {
            char ch = fmt.charAt(a++);
            if (ch != '%') {
               put(ch);
               continue;
            }
            ch = fmt.charAt(a++);
            switch (ch) {
            case 'i':
               put_int((Integer) args[acnt++]); break;
            case 's':
               put_str((String) args[acnt++]); break;
            case 'r':
               put_data((byte[]) args[acnt++]); break;
            case 't':
               tail = (byte[]) args[acnt++];
               tail_count = (Integer) args[acnt++];
               break;
            default:
               put(ch); break;
            }
         }
         int msglen = otmp.size();
         if (tail != null)
            msglen += tail_count;
         write_int(msglen);
         otmp.writeTo(out);
         if (tail != null)
            out.write(tail, 0, tail_count);
      } catch (IOException e) {
         proxy.do_exit(this, 199);
      }
   }