restore error handler
Merge pull request #35 from pentium10/master

restore error handler