Fix up string corruption in diff hunks
Fix up compile bug and remove debug from code