check if safe_mode is enabled (putenv is not allowed then) and