Fixes, sync with upstream 20141024