added per char sync flags, debugged a bit