Skip to content

Commit

Permalink
* Fix one more potential NullPointerException in Parser (issue #30)
Browse files Browse the repository at this point in the history
  • Loading branch information
saudet committed Aug 17, 2015
1 parent 9ed94ed commit 5c259e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/org/bytedeco/javacpp/tools/Parser.java
Original file line number Diff line number Diff line change
Expand Up @@ -1258,7 +1258,7 @@ boolean function(Context context, DeclarationList declList) throws ParserExcepti
for (int n = -2; n < Integer.MAX_VALUE; n++) {
decl = new Declaration();
tokens.index = startIndex;
if (type.constructor || type.destructor || type.operator) {
if ((type.constructor || type.destructor || type.operator) && params != null) {
type = type(context);
params = parameters(context, n / 2, n % 2 != 0);
dcl = new Declarator();
Expand Down

0 comments on commit 5c259e1

Please sign in to comment.