]> git.sur5r.net Git - bacula/bacula/commit
!!! I didn't run the regression tests.!!!
authorMeno Abels <meno.abels@adviser.com>
Thu, 12 Aug 2004 22:13:51 +0000 (22:13 +0000)
committerMeno Abels <meno.abels@adviser.com>
Thu, 12 Aug 2004 22:13:51 +0000 (22:13 +0000)
commitbb827dbd7f8f7421aace966d6c29e42399d01fbd
treeb8f575a0846e3e9f77a41fd58186f1938bc621fe
parentca48808928afdfa126564c721c40a294cb0c2488
!!! I didn't run the regression tests.!!!

1. Find and fix the memory leak (most likely in address_conf.c)

in address_conf there was no memory leak-:) the parser calls my init_default_addresses
but also resets the datastructurs by memset so allocated resource will be lost.
I added the pass number to init_defaults so that i could call my init_default only once
per server.

2. Find some why to have smartalloc work correctly with new.
   *Please* note, you cannot simply put everything on SMARTALLOC --
   this will not work because some of the delete's *must* de-allocate
   all the items in the list. I.e. by default, my lists own the
   list items.

There was a missing  brace
in the use of my new operator to write new(fname, line) Type in the define.
And also there was some operator definitions in dlist,alist,htable which causes
that trouble.
I only added the SMARTALLOC to all classes these are generated by new and removed
by delete.

3. I believe I've fixed the byte order problem by modifying get_port().
   However, if you turn on the debug statement at the top of
   init_bnet() src/lib/bnet.c:917 by setting the 100 to 000, you will
   see that the host address is not correct in all cases.

Kern and I decided to add
 get_port_net_order
 get_port_host_order
 get_first_port_net_order
 get_first_port_host_order
to the code.

4. Eliminate the use of inet_addr() -- it is deprecated.

Done

5. Check the SetIP command in src/dir/fd_cmds.c

fixed mixup of sockaddr and in_addr

6. There is too much #ifdefing in the code to deal with IPv4 and IPv6
   I don't mind it in bnet.c and bnet_server.c (too much), but we should
   try to eliminate it elsewhere.

I cleaned it up.
Is this too much yes it is but, we can't reach the heaven in one day-:)
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#if defined(HAVE_INET_NTOP) && defined(HAVE_IPV6)
./lib/address_conf.c:#ifdef HAVE_IPV6
./lib/address_conf.c:#ifdef HAVE_INET_NTOP
./lib/address_conf.h:#ifdef HAVE_IPV6
./lib/address_conf.h:#ifdef HAVE_IPV6
./lib/address_conf.h:#ifdef HAVE_IPV6
./lib/bnet.c:#ifdef HAVE_IPV6
./lib/bnet.c:#ifdef HAVE_IPV6
./lib/bnet.c:#ifdef HAVE_IPV6
./lib/bnet.c:#ifdef HAVE_IPV6
./lib/bnet.c:#ifdef HAVE_IPV6
./lib/bnet_server.c:#ifndef HAVE_INET_NTOP
./lib/bnet_server.c:#ifdef HAVE_INET_NTOP

git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1517 91ce42f0-d328-0410-95d8-f526ca767f89
19 files changed:
bacula/src/dird/dird.c
bacula/src/dird/dird_conf.c
bacula/src/dird/ua_cmds.c
bacula/src/filed/filed.c
bacula/src/filed/filed_conf.c
bacula/src/lib/address_conf.c
bacula/src/lib/address_conf.h
bacula/src/lib/alist.h
bacula/src/lib/berrno.h
bacula/src/lib/bnet.c
bacula/src/lib/bnet_server.c
bacula/src/lib/dlist.h
bacula/src/lib/htable.h
bacula/src/lib/parse_conf.c
bacula/src/lib/smartall.h
bacula/src/stored/dev.c
bacula/src/stored/read_record.c
bacula/src/stored/stored.c
bacula/src/stored/stored_conf.c