The only parameter passed to gets (or getsx) is a character array to be filled from the input line.
What is actually pushed on the stack is the beginning address of the caller's character array.
No parameter is passed giving the size of this array.
So gets (and getsx) have no way of checking if there is enough room in the array for all the input characters.