5

Spent quite some time debugging an odd problem.

A null check failed to trigger correctly, and when checking in eclipse I saw the null value.

Much digging later I finally noticed that the value wasn't null, it was "null", but eclipse doesn't quote strings...

The problem was that somebody at one time decided to convert an Integer to String by prepending an empty string...

Integer val=getInt()
return "" + val;

Comments
Add Comment