Fix a crash in DiffXFileSection.generate_stats with no diff.
Review Request #11762 — Created July 31, 2021 and submitted
DiffXFileSection.generate_stats()was assuming a diff was set, but
this isn't a requirement for this section (as there may just be metadata
This will now bail immediately if a diff is not set. Statistics in this
case won't be set.
Unit tests pass.