make sure an error is set before printing it
Merge pull request #287 from satta/addintrons-debug

make sure an error is set before printing it