Fix an argument error
Fix a problem emitting wrong SGR attribute after commit