<feed xmlns='http://www.w3.org/2005/Atom'>
<title>libumberlog.git/lib, branch libumberlog-0.2.1</title>
<subtitle>libumberlog patches for integration upstream - branches are rebased</subtitle>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/'/>
<entry>
<title>Reduce the number of memory allocations</title>
<updated>2012-04-29T09:19:06+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@madhouse-project.org</email>
</author>
<published>2012-04-29T09:12:39+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=4fd758dcde350fda5e87573d9c7004a35b136741'/>
<id>4fd758dcde350fda5e87573d9c7004a35b136741</id>
<content type='text'>
Make the string escape use an ul_buffer_t, to avoid unnecessary memory
allocations. This greatly reduces the number of mallocs made, and thus
results in a noticable increase in speed.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make the string escape use an ul_buffer_t, to avoid unnecessary memory
allocations. This greatly reduces the number of mallocs made, and thus
results in a noticable increase in speed.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Generate the manual page if rst2man is present</title>
<updated>2012-04-29T08:35:34+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@madhouse-project.org</email>
</author>
<published>2012-04-29T08:34:04+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=7dc0d11639d5f9fd2c4d0e01ab12813a5898f596'/>
<id>7dc0d11639d5f9fd2c4d0e01ab12813a5898f596</id>
<content type='text'>
If rst2man is present at configure time, generate the manual page with
it, which is to be included in the dist tarball too.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If rst2man is present at configure time, generate the manual page with
it, which is to be included in the dist tarball too.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Preparations for 0.2.1</title>
<updated>2012-04-28T16:47:43+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@madhouse-project.org</email>
</author>
<published>2012-04-28T16:47:43+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=cf66dbeb8820ef935045813598aa5a48be00526a'/>
<id>cf66dbeb8820ef935045813598aa5a48be00526a</id>
<content type='text'>
Bump software and library interface versions, and start adding NEWS
entries.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Bump software and library interface versions, and start adding NEWS
entries.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add a closelog() wrapper to clear the environment</title>
<updated>2012-04-28T16:18:32+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@madhouse-project.org</email>
</author>
<published>2012-04-28T16:18:32+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=8cfef10830350c565e8ee917f83b9e97016a0a62'/>
<id>8cfef10830350c565e8ee917f83b9e97016a0a62</id>
<content type='text'>
Our openlog() wrapper fills in a couple of variables, and those were
kept around even after a closelog(), and thus, affected ul_format()
calls even after a closelog().

This in turn, made one of the test cases fail, as that was relying on
the default behaviour, which was modified due to an openlog() in an
earlier test case.

We now wrap closelog() aswell, and NULL out our settings to get a
clean state, and add a test case to verify this behaviour aswell.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Our openlog() wrapper fills in a couple of variables, and those were
kept around even after a closelog(), and thus, affected ul_format()
calls even after a closelog().

This in turn, made one of the test cases fail, as that was relying on
the default behaviour, which was modified due to an openlog() in an
earlier test case.

We now wrap closelog() aswell, and NULL out our settings to get a
clean state, and add a test case to verify this behaviour aswell.

Signed-off-by: Gergely Nagy &lt;algernon@madhouse-project.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Resolve facility &amp; priority properly</title>
<updated>2012-04-20T11:14:29+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-20T11:14:29+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=5509ee80130cb781d0c88d411021a98b5fab4556'/>
<id>5509ee80130cb781d0c88d411021a98b5fab4556</id>
<content type='text'>
The priority passed to the syslog() call can contain a facility
embedded, so we need to extract it to find both the facility and the
priority.

This also means that the facility set at openlog()-time can be
overridden later, so _find_facility() has to take the priority value
into account.

This patch makes libumberlog do just the above: extract both priority
and facility from the priority passed to syslog(), and if facility is
0, use the default set at openlog()-time, if any.

Added a test case to test this expected behaviour.

Reported-by: Peter Czanik &lt;czanik@balabit.hu&gt;
Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The priority passed to the syslog() call can contain a facility
embedded, so we need to extract it to find both the facility and the
priority.

This also means that the facility set at openlog()-time can be
overridden later, so _find_facility() has to take the priority value
into account.

This patch makes libumberlog do just the above: extract both priority
and facility from the priority passed to syslog(), and if facility is
0, use the default set at openlog()-time, if any.

Added a test case to test this expected behaviour.

Reported-by: Peter Czanik &lt;czanik@balabit.hu&gt;
Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Properly reset the JSON buffer in all cases.</title>
<updated>2012-04-20T10:37:35+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-20T10:37:35+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=32887a13759b27f5b29f585d2b278c225be1fa0d'/>
<id>32887a13759b27f5b29f585d2b278c225be1fa0d</id>
<content type='text'>
Previously the JSON buffer was only reset when ul_vformat() was
called, but not everything goes through that, so some messages ended
up being garbled.

The proper thing to do is to reset in _ul_vformat(), as everything
goes through that, and that's the right place to do this anyway.

Reported-by: Peter Czanik &lt;czanik@balabit.hu&gt;
Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously the JSON buffer was only reset when ul_vformat() was
called, but not everything goes through that, so some messages ended
up being garbled.

The proper thing to do is to reset in _ul_vformat(), as everything
goes through that, and that's the right place to do this anyway.

Reported-by: Peter Czanik &lt;czanik@balabit.hu&gt;
Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Free up the JSON buffer on exit</title>
<updated>2012-04-15T22:36:37+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-15T22:36:37+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=c568a2c036ee555faa7b24cdfe07d65af0a15361'/>
<id>c568a2c036ee555faa7b24cdfe07d65af0a15361</id>
<content type='text'>
This adds a destructor that simply frees up the JSON buffer, so that
to not upset valgrind and similar tools too much.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds a destructor that simply frees up the JSON buffer, so that
to not upset valgrind and similar tools too much.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Improve string escape performance a little</title>
<updated>2012-04-15T22:25:46+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-15T22:25:46+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=142f411b1305d4c9857532f66e61a895604160a9'/>
<id>142f411b1305d4c9857532f66e61a895604160a9</id>
<content type='text'>
Instead of escaping a string, returning a new one and running strlen()
on that, use an output variable to store the length, since we can
easily calculate that during the escape process anyway.

This should shave off a tiny bit of CPU time.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Instead of escaping a string, returning a new one and running strlen()
on that, use an output variable to store the length, since we can
easily calculate that during the escape process anyway.

This should shave off a tiny bit of CPU time.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Correctly NULL-terminate the JSON buffer in all cases.</title>
<updated>2012-04-13T13:01:24+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-13T13:01:24+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=c643e7f035fef390dea1da1eea7757e7368239ce'/>
<id>c643e7f035fef390dea1da1eea7757e7368239ce</id>
<content type='text'>
When finalizing the JSON buffer, always NULL-terminate it at the
appropriate length.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When finalizing the JSON buffer, always NULL-terminate it at the
appropriate length.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Do use the library version</title>
<updated>2012-04-13T12:38:26+00:00</updated>
<author>
<name>Gergely Nagy</name>
<email>algernon@balabit.hu</email>
</author>
<published>2012-04-13T12:38:26+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/mitr/public_git/libumberlog.git/commit/?id=a6314787aba77b94ec4d33d72678a66d31bce0c8'/>
<id>a6314787aba77b94ec4d33d72678a66d31bce0c8</id>
<content type='text'>
We had the LUL_* variables set in lib/Makefile.am, but they weren't
used. Now they are.

While there, bumped LUL_CURRENT to 1, because of the dropped JSON
dependency.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We had the LUL_* variables set in lib/Makefile.am, but they weren't
used. Now they are.

While there, bumped LUL_CURRENT to 1, because of the dropped JSON
dependency.

Signed-off-by: Gergely Nagy &lt;algernon@balabit.hu&gt;
</pre>
</div>
</content>
</entry>
</feed>
