Escaping backslashes when writing Firefox preferences to profile in .NET

Fixes issue #3283.