Fix a NullPointerException in DatabaseUtilities.writeTable
git-svn-id: http://webgoat.googlecode.com/svn/trunk@134 4033779f-a91e-0410-96ef-6bf7bf53c507
This commit is contained in:
parent
b7bb9e4d17
commit
4cae9985f6
@ -158,8 +158,10 @@ public class DatabaseUtilities
|
||||
|
||||
for (int i = 1; i < (numColumns + 1); i++)
|
||||
{
|
||||
row.addElement(new TD(results.getString(i).replaceAll(" ",
|
||||
" ")));
|
||||
String str = results.getString(i);
|
||||
if (str == null)
|
||||
str = "";
|
||||
row.addElement(new TD(str.replaceAll(" ", " ")));
|
||||
}
|
||||
|
||||
t.addElement(row);
|
||||
|
Loading…
x
Reference in New Issue
Block a user