Analyze: set littleEndian flag correctly

Fixes #12471.
Merge pull request #1288 from melissalinkert/rebased/dev_5_0/analyze-endian

Analyze: set littleEndian flag correctly (rebased onto dev_5_0)