This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 308607 - NPE in WebArtifactAdapterFactory
Summary: NPE in WebArtifactAdapterFactory
Status: RESOLVED FIXED
Alias: None
Product: WTP Java EE Tools
Classification: WebTools
Component: jst.j2ee (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.2 M7   Edit
Assignee: Kaloyan Raev CLA
QA Contact: Chuck Bridgham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-09 03:29 EDT by Dimo Stoilov CLA
Modified: 2010-04-19 05:01 EDT (History)
2 users (show)

See Also:
cbridgha: review+


Attachments
the npe (2.14 KB, text/plain)
2010-04-09 03:30 EDT, Dimo Stoilov CLA
no flags Details
patch (3.45 KB, patch)
2010-04-13 06:59 EDT, Kaloyan Raev CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dimo Stoilov CLA 2010-04-09 03:29:44 EDT
the attached NPE appears in the error log while creating servlets in web 2.4 with xdoclet
Comment 1 Dimo Stoilov CLA 2010-04-09 03:30:31 EDT
Created attachment 164339 [details]
the npe
Comment 2 Carl Anderson CLA 2010-04-09 12:51:55 EDT
Kaloyan, since WebArtifactAdapterFactory is a class you introduced in bug 267027, can your team do the initial investigation here?  It looks like a simple null check on servlet.getServletClass().
Comment 3 Kaloyan Raev CLA 2010-04-13 06:59:09 EDT
Created attachment 164684 [details]
patch

Adds NPE checks
Comment 4 Kaloyan Raev CLA 2010-04-13 07:00:28 EDT
Chuck, please approve this patch for 3.2 M7. 
It simply adds several null checks to avoid NPE in some rare cases.
Comment 5 Chuck Bridgham CLA 2010-04-14 14:35:31 EDT
approved
Comment 6 Kaloyan Raev CLA 2010-04-19 05:01:24 EDT
Committed to HEAD and released to build.