Raise exception when not enough memory available