Fixed bugs in ExecEnv