modified source files and error reporting