Fixed wrong usage of new[] in conjunction with unique_ptr.