Fix two issues shown by bug 489995