always free allocated memory.
Add support for DD:STDENV
Add error handling for DD:STDENV stuff