merged with bug4