File dx-4.4.4-mem-leak-fix.patch of Package dx

Index: src/uipp/dxl/send.c
===================================================================
--- src/uipp/dxl/send.c.orig
+++ src/uipp/dxl/send.c
@@ -202,13 +202,14 @@ int     /* packet id that was sent, -1 o
 DXLSendPacket(DXLConnection *conn, DXLPacketTypeEnum ptype, const char *string)
 {
     int l = STRLEN(string);
-    char *buffer = malloc(l + 50);
-    int packetId, sts     = 0;
+    int packetId, sts = 0;
     int written = 0;
 
     if (!conn || conn->fd < 0 || (ptype > _DXLNumPackets) || (ptype <= 0))
         return ERROR;
 
+    char *buffer = malloc(l + 50);
+
     packetId = conn->id++;