One can give sadaqah to the zhimmi and the soldier, and one is rewarded for that. Allah praised a group of people (for this) when He said: “And they feed, for His love, the indigent, orphan, and captive” [ad-Dahr 6]. The captive is a soldier. Allah says: “Allah has not forbidden you with regard to those who have not made war against you on account of [your] faith and have not driven you out of your homes to deal kindly and justly with them; Allah loves those who are just” [al-Mumtahanah 8].
Asma, the daughter of Abu Bakr, reports: “My mother came to me and she is a polytheist. I said: ‘O Messenger of Allah, upon whom be peace! If my mother came to me and she is willing, do I establish a link with her?’ He said: ‘Yes, establish a link with your mother.’ “