Description: Avoid stack smashing in get_port_fmt

Author: Bernhard Übelacker <bernhardu@mailbox.org>
Bug-Debian: https://bugs.debian.org/733304
Last-Update: 2018-07-30

--- wput-0.6.2+git20130413.orig/src/utils.c
+++ wput-0.6.2+git20130413/src/utils.c
@@ -77,7 +77,7 @@ char * get_port_fmt(int ip, unsigned int
     static char buf[6 * 4];
     /* TODO USS have we got an endian problem here for the ip-address */
     *         (int *) b    = ip;
-    *(unsigned int *)(b+4) = htons(port);
+    *(uint16_t *)(b+4) = htons(port);
     sprintf(buf, "%d,%d,%d,%d,%d,%d", b[0], b[1], b[2], b[3], b[4], b[5]);
     return buf;        
 }
