cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ugo Cei <>
Subject Re: DO NOT REPLY [Bug 17673] - sendPage function in Flow causes an NPE.
Date Mon, 10 Mar 2003 10:49:42 GMT
Carsten Ziegeler wrote:
> Ugo Cei wrote:
>>Is this a case of not enough defensive programming or do the NPEs that
>>occur when the checks are not in place a symptom of a problem somewhere
>>else that the checks merely hide from view?
> Yes, this should be the case, the problem should lie somewhere else. That's
> exactly why I removed the null checks from the code above. Because *if*
> everything is working properly, an NPE can never occur.
> Carsten

In that case, maybe, wouldn't keeping the checks (better safe than sorry 
;-) ) and adding an assertion for debugging be The Right Thing (TM) to 
do? What do you think?


Ugo Cei - Consorzio di Bioingegneria e Informatica Medica
P.le Volontari del Sangue, 2 - 27100 Pavia - Italy
Phone: +39.0382.525100 - E-mail:

View raw message