Generating different content when creating picture on different machines
<p>I want to create a picture from a passed binary string:</p>

<pre><code>$fileName = uniqid().".".$imgType;
$fileName = "../tmp/".$fileName;
$f = fopen($fileName,'wb');
$picture =  mb_convert_encoding($picture, "UUENCODE", "UTF-8");

fwrite($f, $picture);


fclose($f);
</code></pre>

<p>This works quite well on one machine with PHP 5.3.10-1ubuntu3.4. The picture is created properly. If try it on a different machine with PHP 5.3.19 the output is very strange. E.g. if you open the file with <code>less</code> then you will find <code>\0</code> instead of desired <code>^@</code> characters.</p>

<p><strong>Why does this happen?</strong></p>

<p>The binary string is part of a post request from a website using HTML5 Formdata encoded in both cases with UTF-8.</p>
