This patch no longer applies to master, please submit a rebased version to thethread. I've marked the CF entry as waiting for author in the meantime.
--Daniel Gustafsson