Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
malik:29-93

Yahya related to me from Malik from Nafi that Abdullah ibn Umar was asked about a woman whose husband died while she was pregnant, and he said, "When she gives birth, she is free to marry." A man of the Ansar who was with him told him that Umar ibn al-Khattab had said, "Had she given birth while her husband was still on his bed, unburied, she would be free to marry."  

مالك:٢٩-٩٣وَحَدَّثَنِي عَنْ مَالِكٍ عَنْ نَافِعٍ عَنْ عَبْدِ اللَّهِ بْنِ عُمَرَ

أَنَّهُ سُئِلَ عَنِ الْمَرْأَةِ يُتَوَفَّى عَنْهَا زَوْجُهَا وَهِيَ حَامِلٌ فَقَالَ عَبْدُ اللَّهِ بْنُ عُمَرَ إِذَا وَضَعَتْ حَمْلَهَا فَقَدْ حَلَّتْ فَأَخْبَرَهُ رَجُلٌ مِنَ الأَنْصَارِ كَانَ عِنْدَهُ أَنَّ عُمَرَ بْنَ الْخَطَّابِ قَالَ لَوْ وَضَعَتْ وَزَوْجُهَا عَلَى سَرِيرِهِ لَمْ يُدْفَنْ بَعْدُ لَحَلَّتْ