patched to work on atleast nma v6.25