Detailed Explanation
Tom the Trucker invokes the following laws.
1. A commissioned B to perform a defined service. After performing part of the service, B legitimately (see Choshen Mishpat 333: 1-4) backed out of the job. A pays B for any benefit he/she received from having part of the service rendered. A is absolved from paying B if he/she received no benefit from a partial service rendered [Choshen Mishpat 333, Nesivos 333: Biurim 9].
2. A commissioned B to work for a specified time period. B fell ill; whereby becoming incapable of working. Barring contractual agreements, A is absolved for paying for the time B was unable to perform.
3. A prepaid B. B fell ill; whereby becoming incapable of working.
3.1 Rema maintains that A assumed the calculated risk that an uncontrollable phenomenon like illness may occur and nevertheless willingly awarded the money to B. As such, A may not demand B to refund the money if uncontrollable circumstances indeed occurred and deemed it impossible to complete the contract.
3.2 However, Sha"ch opines that by nature, an employer does not "purchase an employee, come what may" but merely pays for services rendered. As such, A may demand B to refund the wages forwarded for services ultimately not rendered [Choshen Mishpat 333: 5, Sha"ch 25].
4. A prepaid B. B died.
4.1 In line with Rema's aforementioned school of thought, Aruch Hashulchan rules that A may not compel B's heirs to refund him/her for the part of the service not rendered [Aruch Hashulchan Choshen Mishpat 329:2].
4.2 In line with Sha"ch's school of thought, Nesivos rules that A may not compel B's heirs to refund him/her for the part of the service not rendered if the heirs wish to complete their father's job. Otherwise, A may compel B's heirs to refund the wages forwarded for services ultimately not rendered [Nesivos: Choshen Mishpat 329:1].
Application
As opposed to receiving an hourly wage, Tom was commissioned to complete a job. Karmin's truck was decimated. Tom did not survive. Karmin did not benefit from Tom's services and as such is absolved from paying Tom or his heirs.
Were Karmin to have prepaid Tom for his services, Nesivos would rule that Karmin may not demand the heirs to refund the money if they are willing to perform the job. Aruch Hashulchan would rule that Karmin could never compel Tom's heirs to refund the money.
That being said, as in general when two legitimate conflicting Halachic views, the Lower Court employs the formula of hamotzi mechaveiro alav harayah whereby respecting the status quo and would permit the heirs to keep the money without having to ship a kitchen for Karmin.