summaryrefslogtreecommitdiffstats
path: root/source/lib/talloc.c
Commit message (Collapse)AuthorAgeFilesLines
* Move to talloc control of SPOOL_XXX structs. Move to talloc control ofJeremy Allison2001-02-281-0/+13
| | | | | security descriptors and pointers. Syncup with 2.2 tree. Jeremy.
* Added total memory allocated counter to talloc, so we can tell if a tallocJeremy Allison2001-02-271-0/+22
| | | | | | | pool is getting bloated. Also added a talloc_zero function to return zeroed memory. Added debug in rpc_server/srv_pipe_hnd.c so we know when a talloc pool is being freed. Syncup with srv_pipe_hnd.c from 2.2 so we are freeing memory at the same time. Jeremy.
* Fixed memory leaks in lsa_XX calls. Fixed memory leaks in smbcacls. MergedJeremy Allison2000-12-151-0/+5
| | | | | | in fixes from appliance-head and 2.2. Fixed multiple connection.tdb open problem. Jeremy.
* reworked talloc() to in order to help track down invalidGerald Carter2000-08-121-25/+26
| | | | | | | | | | | | | | | | | memory access. Tridge, I don't think using 0xdeadbeef for size allocations of 0 is going to work. I ended up having to use NULL as much code that works on UNISTR checks to see if the buffer ptr is NULL. So valid code ends up with a seg fault. Rather than rewriting it all, I added a DEBUG_TALLOC #ifdef in talloc.h that sets a macro BAD_PTR. This is the value assigned to ptr for an allocation of 0 bytes. jerry
* talloc returns 0xdeadbeef when asked to allocate 0 bytesGerald Carter2000-08-101-19/+29
| | | | jerry
* Ok - this is a *BIG* change - but it fixes the problems with static stringsJeremy Allison2000-07-271-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | in the RPC code. This change was prompted by trying to save a long (>256) character comment in the printer properties page. The new system associates a TALLOC_CTX with the pipe struct, and frees the pool on return of a complete PDU. A global TALLOC_CTX is used for the odd buffer allocated in the BUFFERxx code, and is freed in the main loop. This code works with insure, and seems to be free of memory leaks and crashes (so far) but there are probably the occasional problem with code that uses UNISTRxx structs on the stack and expects them to contain storage without doing a init_unistrXX(). This means that rpcclient will probably be horribly broken. A TALLOC_CTX also needed associating with the struct cli_state also, to make the prs_xx code there work. The main interface change is the addition of a TALLOC_CTX to the prs_init calls - used for dynamic allocation in the prs_XXX calls. Now this is in place it should make dynamic allocation of all RPC memory on unmarshall *much* easier to fix. Jeremy.
* fixed size alignment in tallocAndrew Tridgell2000-06-261-2/+2
|
* Fixed pointer arithmetic found by IRIX compiler.Jeremy Allison2000-01-111-1/+1
| | | | Jeremy.
* implemented talloc() as described on samba-technical. This fixes theAndrew Tridgell2000-01-051-0/+96
lp_string() bug properly. we still need to add lp_talloc_free() calls in all the main event loops, I've only put it in smbd and nmbd thus far.