On Wed, 14 Jan 2026 10:21:40 GMT, Anupam Dev <[email protected]> wrote:

> Hi,
> 
> This is a fix for NPE in OldJTable.addColumn
> 
> The addColumn method in OldJTable.java was unconditionally calling 
> columnData.toArray(), which caused a NullPointerException when columnData was 
> null (e.g., when called from addColumn(Object, int)).
> 
> This commit adds a null check to safe-guard against this NPE, passing null to 
> the underlying DefaultTableModel when columnData is missing.
> 
> Kindly review.
> 
> Regards,
> Anupam

This pull request has now been integrated.

Changeset: 9470aa31
Author:    Anupam Dev <[email protected]>
Committer: Phil Race <[email protected]>
URL:       
https://git.openjdk.org/jdk/commit/9470aa31175b504fcef15a932825dbc9e0532234
Stats:     264 lines in 1 file changed: 0 ins; 264 del; 0 mod

8375011: OldJTable.java - NullPointerException when columnData is null

Reviewed-by: prr, psadhukhan, tr

-------------

PR: https://git.openjdk.org/jdk/pull/29226

Reply via email to