appplying patch