Add `env_free`

Fixes #1.
Merge pull request #2 from mmalecki/add-env-free

Add `env_free`