Internally the socket creation for UDP uses an argument called SO_REUSEADDR. This is used on both the windows and linux versions of AGK. (if you want exclusive access you would use SO_EXCLUSIVEADDRUSE)
What that essentially means is that the socket CAN have multiple listeners bound to it. Typically that is to allow multicasting using UDP to multiple apps on one machine which can be quite useful.
Quote: "Only one usage of each socket address (protocol/network address/port) is normally permitted.
An error is returned if a process on the computer is already bound to the same fully qualified address and the socket has not been marked to allow address reuse with SO_REUSEADDR. For example, the IP address and port specified in the name parameter are already bound to another socket being used by another application. For more information, see the SO_REUSEADDR socket option in the SOL_SOCKET Socket Options reference, Using SO_REUSEADDR and SO_EXCLUSIVEADDRUSE."
I suppose that makes the documentation somewhat incorrect which does state that if the port is used then it will return 0 - except that it doesn't and will succeed depending on the OS's implementation of the sockets API it uses.
https://www.appgamekit.com/documentation/Reference/Multiplayer/CreateUDPListener.htm
So...not sure its a bug or...incorrect documentation ??