To his Turkish hosts, Rifai Ahmed Taha was a tiny, elf-like man with an oversize beard and colorful past. To U.S. officials, he was a dangerous terrorist who would be tracked and targeted — if ever he left his Turkish sanctuary.

The opportunity came in early April, when Taha ventured across the border into Syria for a meeting with Islamist militants. Just five days later, a U.S. drone fired a missile at the Egyptian’s car as it stopped for gas near the Syrian city of Idlib, killing him and four other suspected jihadists.

The strike ended the career of a man who had been an ally of ­Osama bin Laden and, more recently, an adviser to Syrian rebels linked to al-Qaeda. It also highlighted what U.S. terrorism experts view as Turkish schizophrenia when it comes to battling violent jihadists: Even as Turkey ramps up its campaign against the Islamic State, it continues to tolerate and even protect other Islamists designated by Western governments as terrorists.

Turkey has defended its policy of giving refuge to exiled supporters of Egypt’s Muslim Brotherhood government, which was overthrown in a coup in 2013. But among those offered shelter in Turkey are leaders of the Egyptian group Gamaa Islamiya, , whose members carried out murderous attacks against tourists in Egypt in the 1990s and were later tied to multiple plots to kill Americans.