On 10/10/11 08:06, Andrew Beverley wrote:
On Sat, 2011-10-08 at 21:18 +0200, Henrik Nordström wrote:
fre 2011-10-07 klockan 19:18 +0100 skrev Andrew Beverley:

I admit that I am rushing to submit this as I go away for the weekend,
so please let me know if it's not up to scratch! Works For Me (TM)
though.

Why are you allocating the DBT structures?

With the newer version of Berkeley DB, the structures need to be
initialised to null before use. I thought that in order to do so, I had
to allocate the memory. This was wrong, so I have now just made sure
that they are properly initiated before use in the new patch attached.

Also you are not freeing them, causing a memory leak on each lookup.


Good point, although I've remove the malloc now as above.

I've made a couple of other minor changes - please find updated patch
attached for merge assuming you are happy with it. When using the DB
environment, I have hard-coded the name of the database file within the
directory. I can't see any problems with this, but please let me know if
you disagree (I did originally used program_name, but this doesn't work
when it contains the full path).

I have also removed the ->sync calls, as these are not required with the
improved synchronisation of the DB environment.

Finally, I noticed that in doc/manuals/* there is references to the
session helper. Should I be updating these files as well? If so, why is
the information repeated between that location and the session helper
manual in helpers/external_acl/session/?

doc/manuals/* are translations auto-generated from the helper .8 file during release. No need to worry about them unless there is a bug in their creation.

Amos
--
Please be using
  Current Stable Squid 2.7.STABLE9 or 3.1.15
  Beta testers wanted for 3.2.0.12

Reply via email to