Fix broken file uploads in Sf2.2 + php5.4