sr_report_to_json: do not segfault on invalid reports

Signed-off-by: Michal Toman <mtoman@redhat.com>
Signed-off-by: Jakub Filak <jfilak@redhat.com>