On Mon, September 12, 2005 11:59 am, Hirmke Michael wrote: >> You may use eval { ... } around the above piece of code to >> catch the error. > > I already tried it - didn't help in any way. > > > eval { $oSASL = Authen::SASL->new( > mechanism => "GSSAPI", > callback => { > user => ' ', > }, > ); }; > > died with exact the same error message. > Or is there anything wrong with that eval statement above?
The eval should have caught the die. However I would personally have placed the assignment outside the eval $oSASL = eval { Authen::SASL->new( mechanism => "GSSAPI", callback => { user => ' ', }, ) }; This should not cause you application to exit, but $oSASL would be undef and the error message you saw previously should be in $@ Graham.