All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
No doubt, sincerely wishing martyrdom is a form of getting closer to Allaah. So, one may get it even if he does not die on the battle field.
The Prophet said: "Whoever seeks martyrdom with sincerity will be ranked by Allaah among the martyrs even if he dies on his bed" [Muslim]. The response to a supplication is among the With regard to the supplication being answered, it is a matter of the unseen and no ruling applies to it in regard to the Muslim, as the supplication might be responded to and it might not, as there are some impediments which prevent the supplication from being answered.
Therefore, the sister should not regret wishing martyrdom, and if you want that Allaah gathers you with your husband and children, then you may combine between both wishes, enjoying a long life and getting martyrdom.
So, you may ask Allaah saying: "O Allaah I ask you to give me a long life with my husband and children and grant me martyrdom in the Cause of Allaah." No doubt, this supplication is more preferred than asking for a long life only. Asking for a long life is allowed, especially if the aim is to worship Allaah.
We would like to remind you of two important matters:
1. Martyrs get a more comfortable, better and great life after martyrdom which is beyond our imagination. Allah says in this concern (what means): {And never think of those who have been killed in the cause of Allaah as dead. Rather, they are alive with their Lord, receiving provision. Rejoicing in what Allaah has bestowed upon them of His bounty.} [Quran 3:169-170]
2. A Muslim who has a great determination should not wish and ask for a long life only to live and to amuse oneself rather he/she should ask for a long life to worship Allaah and do more good deeds to get closer to Allaah in order to get high status in Paradise.
Allaah Knows best.