I'm just curious whether different message.type() values are expected: if not it's worth adding "default: DCHEK(false) << "Never reach""; if yes, it looks better IMHO to have "if(message.type()  == PpapiHostMsg_UMA_Create::ID)"  instead of "switch case"