In castle/fortress design, what do you call the wall placed immediately inside the gates that prevents the enemy from having a straight shot into your fortress?
In castle/fortress design, what do you call the wall placed immediately inside the gates that prevents the enemy from having a straight shot into your fortress?

imgur.com

You see something similar in the entranceway to public bathrooms that don't have doors, where it kind of zig-zags for privacy. I'm trying to figure out what this kind of architectural feature is called. Thanks!