title: how can I use linux command sed to process Little-endian UTF-16 file
body: <p>I am working on an application about windows rdp. Now I get a problem when I try to use the sed command to replace the string of IP address directly in the rdp file. But after executing this command, the origin rdp file is garbled. </p>
  
  <pre><code>sed -i "s/address:s:.*/address:s:$(cat check-free-ip.to.rdpzhitong.rdp)/" rdpzhitong.rdp
  </code></pre>
  
  <p>I find that the file's format is Little-endian UTF-16 Unicode. </p>
  
  <p><img src="https://i.stack.imgur.com/3bJbg.png" alt="enter image description here"></p>
  
  <p>Can I still use the sed command to replace the text in the files correctly? Or other method to process this problem?</p>