title: "get" string from tk text widget changes when passed to proc
body: <p>I've run into an issue I can't explain and have found nothing online that explains it. In my TCL/TK script's toplevel window, there is a text widget, the value of which can be called and passed to a procedure that decrypts the hex within the widget. The widget might contain normal text to be encrypted, or encrypted hex to be decrypted. Where I'm having the problem is in pasting or reading from file encrypted hex to the text widget, and then passing that on:</p>
  <pre><code>proc decrypt {password tte} {
       &lt;do some stuff&gt;
  }
  &lt;some scripting&gt;
  set tte [.verybottom.lb get 1.0 end]
  decrypt $password $tte
  </code></pre>
  <p>The encrypted hex will not decrypt and will err <em>unless</em> the original text before encryption was &gt; 31 characters, at which point it will decrypt normally. However, if I move that line the the actual proc:</p>
  <pre><code>proc decrypt {password}
       set tte [.verybottom.lb get 1.0 end]
       &lt;do some stuff&gt;
  }
  </code></pre>
  <p>It works just fine. I'm obviously missing something, and because there's encryption / decryption involved, every bit counts. Maybe someone has run into this.</p>