check_rtp_origin(): Avoid using memcmp for comparing integer types

in_addr consists only of s_addr, which is an integer type that
can be compared directly.  By avoiding memcmp() here we would have
been able to catch Coverity CID#188874 even without Coverity, and
make the code more compact...

Change-Id: Ic6105d39ae2fb4b301f87448b16763fe9f695621
diff --git a/src/libosmo-mgcp/mgcp_network.c b/src/libosmo-mgcp/mgcp_network.c
index fe63f1e..de34cc6 100644
--- a/src/libosmo-mgcp/mgcp_network.c
+++ b/src/libosmo-mgcp/mgcp_network.c
@@ -872,9 +872,8 @@
 {
 	struct mgcp_endpoint *endp;
 	endp = conn->conn->endp;
-	struct sockaddr_in zero_addr = {};
 
-	if (memcmp(&zero_addr.sin_addr, &conn->end.addr, sizeof(zero_addr.sin_addr)) == 0) {
+	if (conn->end.addr.s_addr == 0) {
 		switch (conn->conn->mode) {
 		case MGCP_CONN_LOOPBACK:
 			/* HACK: for IuUP, we want to reply with an IuUP Initialization ACK upon the first RTP
@@ -904,8 +903,7 @@
 
 	/* Note: Check if the inbound RTP data comes from the same host to
 	 * which we send our outgoing RTP traffic. */
-	if (memcmp(&addr->sin_addr, &conn->end.addr, sizeof(addr->sin_addr))
-	    != 0) {
+	if (conn->end.addr.s_addr != addr->sin_addr.s_addr) {
 		LOGP(DRTP, LOGL_ERROR,
 		     "endpoint:0x%x data from wrong address: %s, ",
 		     ENDPOINT_NUMBER(endp), inet_ntoa(addr->sin_addr));