Merge pull request #35 from pentium10/master

restore error handler