Since for some reason, the native headers sometimes are immutable even though the accessor says that the headers are mutable, then we have to ensure their * mutability. We do so by first making a mutable copy of the native headers, then by removing the native headers from the headers map and replacing them with a mutable copy fixes #1184