Going through pre-clearance in Canada would put you at much lower risk of hoover-age by ICE. According to the Preclearance Act all CBP can do is detain you until they hand you over to the Canadian police - section 14(2) - ... and maybe a light strip search if the situation warrants - section 13(1). [1]
[1] https://laws-lois.justice.gc.ca/eng/acts/P-19.32/FullText.ht...
[edit] There's also pre-clearance facilities at Dublin and Shannon in Ireland, and sprinkled around the Caribbean. Abu Dhabi has one but visiting Emirati jail is not top of my to-do list.