Fix another giant batch of resource leaks. (Mostly memory, but there's
[u/mdw/putty] / unix / uxser.c
index 8f4955c..e45f3ae 100644 (file)
@@ -308,6 +308,7 @@ static const char *serial_init(void *frontend_handle, void **backend_handle,
     {
        char *msg = dupprintf("Opening serial device %s", line);
        logevent(serial->frontend, msg);
+        sfree(msg);
     }
 
     serial->fd = open(line, O_RDWR | O_NOCTTY | O_NDELAY | O_NONBLOCK);