UELinkerFixups.cpp: error C2078: too many initializers

Migrating to 4.19.2, I’m getting errors on Linux and Win64.

Linux cross-compile

/Intermediate/Build/Linux/B4D820EA/Descent/Development/UELinkerFixups.cpp(809,194): error : excess elements in array initializer

Win64

\Development\UELinkerFixups.cpp(899): error C2078: too many initializers




I realize there are too many elements, but does anyone know what would cause it to generate too many elements?

static void EncryptionKeyCallback(unsigned char OutKey[32])
	{
    		const unsigned char Key[32] = {0x65,0x33,0x56,0x71,0x67,0x53,0x4D,0x68,0x75,0x61,0x50,0x77,0x37,0x35,0x66,0x6D,0x30,0x50,0x64,0x47,0x5A,0x43,0x4E,0x33,0x41,0x53,0x77,0x70,0x56,0x4F,0x6B,0x35,0x49,0x6A,0x37,0x69,0x4C,0x66,0x38,0x56,0x4F,0x45,0x64,0x71,0x47,0x4C,0x36,0x61,0x77,0x30,0x35,0x4A,0x65,0x58,0x30,0x52,0x48,0x4D,0x67,0x42,0x76,0x79,0x70,0x64};
    		for (int ByteIndex = 0; ByteIndex < 32; ++ByteIndex)
    		{
    			OutKey[ByteIndex] = Key[ByteIndex];
    		}
    	}

Am I doing something stupid?

Next step is to debug through the generation of this file, but, thought someone might know before I open up that can of worms.

Thanks for any help!

I had the same error in Win64 development build (C2078: too many initializers).
It looks like this can be fixed by clearing and generating a new encryption key from Project Settings → Project → Crypto. This worked for me at least.
Anyway, after generating a new key I saw this line close to the end of the build log, even if build was successful:

UATHelper: Packaging (Windows (64-bit)):   LogPakFile: Error: Keys do not properly encrypt/decrypt data (failed test with 11)

Not sure if it’s something to worry about…need to do some tests.
Hope it helps.
Cheers!

Indeed…the build was successful but the packaged game crashed on start. I fixed it by also generating new signing keys (which unsurprisingly prevented that error in the log).

Thank you, I will try this out this weekend and let you know!

That was it, thanks!