The stock market mounted a last-minute rally to keep its string of winning days alive, as all three major market benchmarks recovered from losses during most of the day to close higher. The performance again showed the complete confidence that investors seem to have in the market’s longer-term future, despite the fact that some believe that stocks have generally risen too quickly and have been hoping for a pullback. Enough investors seem to be waiting for an opportunity to buy that losses have generally been muted and short-lived.