(CNBC) Stocks rose on Thursday, but gains were capped as disappointing holiday sales from Macy’s and a revenue guidance cut from American Airlines pressured retail and airline shares. Fear that the U.S. government shutdown might continue for a long time also pushed equities lower.

The Dow Jones Industrial Average rose 117 points while the S&P 500 traded 0.4 percent higher. The Nasdaq Composite climbed 0.4 percent. The three indexes were on track to close higher for the fifth straight session.

Macy’s shares tanked more than 18 percent — on pace for their worst day every — after reporting its same-store sales grew by just 1.1 percent in November and December. The company also cut its earnings and revenue forecast for fiscal 2018.

Note: Read our discussion guidelines before commenting.