<html>
<head>
</head>
<body>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">Hi </font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font size="2" face="Dialog">Due to my company firewall, I do not have access to the git public repository, so I will post this here.</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">I believe there is a memory leak when duplicate messages are suppressed and messages cannot be consumed:</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">logwriter.c: log_writer_last_msg_flush(LogWriter *self)</font> </p>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">-------------------------------------------</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">log_queue_push_tail(self->queue, m, &path_options) can return FALSE (message cannot be consumed), in which case the local LogMessage m is leaked.</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">The fix should be something like</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2"> if (!log_queue_push_tail(self->queue, m, &path_options))</font> </p>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2"> {</font> </p>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2"> log_msg_unref(m);</font> </p>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2"> }</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">Regards</font> </p>
<br>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Dialog" size="2">Andy Kitchingman</font> </p>
<br> <br><br>
</body>
</html>