Some changes to message code that were added before but never committed