Imported Upstream version 585