Rollover risk and credit risk under time-varying margin