How do I report capital gains upon liquidation (within 30 days of death) of a brokerage account for a deceased taxpayer? Funds distributed to beneficiaries after liq.

I thought these assets would transfer at market value on DOD, but the broker is reporting the gains on Form 8949.