Process for the treatment of metalliferous residues in petroleum tars gasification plants