Changing back to defining frame header and mask outside of websocketframe. Going back to creating new buffer for data passed in to handlesocketdata in connection as that does seem to be a major cause of retained memory. The problem is it causes lots of garbage. Hoping to offset that by reverting the header and mask buffer definitions.