Hello, this is an updated version of the patch that is rebased on 'master' and with some style fixes.