AMENDMENT NO. 4 TO CREDIT AGREEMENT AND WAIVER EXTENSION AGREEMENT