fixed incompatibility with system getline()
Fix memory corruption as of issue #2
Merge branch 'master' into testsuite