Skip to content

[Fixes #79] NPE hides outer exception#82

Merged
aaime merged 1 commit into
mapfish:mainfrom
etj:79_main_npe
Jun 15, 2026
Merged

[Fixes #79] NPE hides outer exception#82
aaime merged 1 commit into
mapfish:mainfrom
etj:79_main_npe

Conversation

@etj

@etj etj commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Fixes #79 on main

Copilot AI review requested due to automatic review settings June 15, 2026 13:01

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds a null-guard when cleaning up temporary files during PDF creation failures to avoid secondary exceptions masking the original error.

Changes:

  • Guard deleteFile(...) behind a tempFileMetadata != null check in the catch block.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 205 to 209
} catch (Throwable e) {
deleteFile(tempFileMetadata.tempFile);
if (tempFileMetadata != null) {
deleteFile(tempFileMetadata.tempFile);
}
error(httpServletResponse, e);
@aaime aaime merged commit 666b7b4 into mapfish:main Jun 15, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NPE hides outer exception

3 participants