code: private void writeString(int fd, String s) throws IOException {
          if (s.length() > 0) {
              byte b[];
              try {
                  b = s.getBytes("UTF-8");
              } catch (java.io.UnsupportedEncodingException x) {
                  throw new InternalError();
              }
              BsdVirtualMachine.write(fd, b, 0, b.length);
          }
          byte b[] = new byte[1];
          b[0] = 0;
          write(fd, b, 0, 1);
      }
docs: /*
  Write/sends the given to the target VM. String is transmitted in
  UTF-8 encoding.