Imported upstream 1.2.6