Andrej Vodopivec is right: 1.) This patch is needed for windows only and 2.) there is a dedicated function that does do exactly what I want from it => revised the patch.