fixes #1 and fixes #2 in GitHub issue tracking

This commit fixes (thank you Wilfried Middleton) two
issues with the template engine as described by the issues
referred. The engine did previously not handle \r\n
line feeds correctly and also did not handle non-executed
if statement string sections correctly.