update diff pointer