Patch to fix Bugzilla Bug #603: Batch export crashes