More refactoring. Fixed lots of ByteBuf leaks. Fixed weird error @FlashPolicyDecoder.