Updates/fixes from marc-mabe code review