This paper studies the transmission of financial shocks in a model where corporate credit is intermediated via both banks and bond markets. In choosing between bank and bond financing, firms trade off the greater flexibility of banks in case of financial distress against the lower marginal costs of large bond issuances. I find that, in response to a contraction in bank credit supply, aggregate bond issuance in the corporate sector increases, but not enough to avoid a decline in aggregate borrowing and investment. Keeping leverage constant while retiring bank debt would expose firms to a higher risk of financial distress; they offset this by reducing total borrowing. A calibration of the model to the Great Recession indicates that this precautionary mechanism can account for one-third of the total decline in investment by firms with access to bond markets.