Fix memory corruption on low memory.

The change fixes initialization handling such that memory would not be corrupted when self is nil (i.e. under low memory).