summaryrefslogtreecommitdiff
path: root/source3/registry/reg_perfcount.c
AgeCommit message (Collapse)AuthorFilesLines
2011-06-09s3-talloc Change TALLOC_ZERO_ARRAY() to talloc_zero_array()Andrew Bartlett1-1/+1
Using the standard macro makes it easier to move code into common, as TALLOC_ZERO_ARRAY isn't standard talloc.
2011-06-09s3-talloc Change TALLOC_REALLOC_ARRAY() to talloc_realloc()Andrew Bartlett1-10/+10
Using the standard macro makes it easier to move code into common, as TALLOC_REALLOC_ARRAY isn't standard talloc. Andrew Bartlett
2011-05-06s3: only include tdb headers where needed.Günther Deschner1-0/+1
Guenther
2011-03-30registry: create and use shared libcli/registry/util_reg.h header.Günther Deschner1-0/+1
Guenther
2011-03-30s3-includes: only include system/filesys.h when needed.Günther Deschner1-0/+1
Guenther
2011-02-07s3-perfcount: Create the directory on tdb open.Andreas Schneider1-15/+5
Signed-off-by: Günther Deschner <gd@samba.org>
2010-10-27Fix bug 7754 - samba uses index(), marked as legacy.Sven Neumann1-3/+3
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Oct 27 19:25:16 UTC 2010 on sn-devel-104
2010-05-25s3:registry: extract reg_perfcount prototypes into header of their own.Michael Adam1-0/+1
And use them only when necessary.
2010-05-18s3: Remove use of iconv_convenience.Jelmer Vernooij1-2/+2
2010-05-18s3-registry: only include registry headers when really needed.Günther Deschner1-0/+1
Guenther
2010-05-06s3: only include gen_ndr headers where needed.Günther Deschner1-0/+1
This shrinks include/includes.h.gch by the size of 7 MB and reduces build time as follows: ccache build w/o patch real 4m21.529s ccache build with patch real 3m6.402s pch build w/o patch real 4m26.318s pch build with patch real 3m6.932s Guenther
2010-04-09s3: add iconv_convenience handle to pull/push sz helpers.Günther Deschner1-2/+2
Guenther
2009-10-01s3-perfcount: more cleanup.Günther Deschner1-41/+39
Guenther
2009-10-01s3-perfcount: only pass down prs_struct when really required.Günther Deschner1-26/+27
Guenther
2009-10-01s3: add perfcount idl and generated files.Günther Deschner1-43/+85
Guenther
2009-09-30s3-registry: use push_reg_sz().Günther Deschner1-5/+5
Guenther
2009-03-17s3-spoolss: move SYSTEMTIME parsing to a more generic place, as suggested.Günther Deschner1-1/+1
Guenther
2009-02-14Remove a pointless NULL checkVolker Lendecke1-3/+0
2009-02-14Fix some nonempty blank linesVolker Lendecke1-22/+22
2008-10-18Use separate make variables for libutil and libcrypto.Jelmer Vernooij1-1/+1
2008-10-14Use {u,}int64_t instead of SMB_BIG_{U,}INT.Jelmer Vernooij1-5/+5
2008-03-21Fix Coverity ID 506Volker Lendecke1-1/+4
(This used to be commit c9add4d59a1615aabc565e323cb19cf7ef4b6b64)
2007-11-30Fix _reg_perfcount_get_instance_info()Günther Deschner1-1/+1
Guenther (This used to be commit 20c1ba23f2e2902ef7c2237c63addfef2ae75eac)
2007-11-26Remove pstrings from nsswitch/ and registry/Jeremy Allison1-19/+31
Jeremy. (This used to be commit 331c0d6216e1a1607a49ed7eb4078e10138ec16a)
2007-11-01Patch 2 of 3 from Debian Samba packagers:Gerald (Jerry) Carter1-2/+2
The point is doing the following associations: - non discardable state data (all TDB files that may need to be backed up) go to statedir - shared data (codepage stuff) go to codepagedir The patch *does not change* the default location for these directories. So, there is no behaviour change when applying it. The main change is for samba developers who have to think when dealing with files that previously pertained to libdir whether they: - go in statedir - go in codepagedir - stay in libdir (This used to be commit d6cdbfd875bb2653e831d314726c3240beb0a96b)
2007-10-18RIP BOOL. Convert BOOL -> bool. I found a few interestingJeremy Allison1-21/+21
bugs in various places whilst doing this (places that assumed BOOL == int). I also need to fix the Samba4 pidl generation (next checkin). Jeremy. (This used to be commit f35a266b3cbb3e5fa6a86be60f34fe340a3ca71f)
2007-10-10r25417: Use DBGC_REGISTRY class.Günther Deschner1-1/+1
Guenther (This used to be commit 43ca04918a5a1b2379083dc624b346ceb8476a38)
2007-10-10r24949: Remove some static buffersVolker Lendecke1-2/+2
(This used to be commit df648d47ff3c4e24f439fda839653bda98323100)
2007-10-10r23801: The FSF has moved around a lot. This fixes their Mass Ave address.Andrew Tridgell1-2/+1
(This used to be commit 87c91e4362c51819032bfbebbb273c52e203b227)
2007-10-10r23779: Change from v2 or later to v3 or later.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 407e6e695b8366369b7c76af1ff76869b45347b3)
2007-10-10r22009: change TDB_DATA from char * to unsigned char *Stefan Metzmacher1-1/+1
and fix all compiler warnings in the users metze (This used to be commit 3a28443079c141a6ce8182c65b56ca210e34f37f)
2007-10-10r21979: make use of string_tdb_data()Stefan Metzmacher1-6/+3
to avoid creating the TDB_DATA struct from strings "by hand" note: we can't use the tdb_*_bystring functions here, as the key isn't null-terminated here... metze (This used to be commit 29b42ea89cbdd9f2c12fa448b116c49669467faf)
2007-10-10r20269: merge -r20264:20267 from SAMBA_3_0_24Herb Lewis1-0/+2
more no previous prototype warnings (This used to be commit 41be182f78762372ae13759ede5d2bd40a71d7f5)
2007-10-10r19913: Fix a const warningVolker Lendecke1-1/+1
(This used to be commit a660993d140b860691c3ed0b71d3e8023e5a7c57)
2007-10-10r19858: Fix a memleak, add a constVolker Lendecke1-1/+2
(This used to be commit ed4dc405127cefd1c222e1bdd63fcaaae8e83f13)
2007-10-10r19853: Update a linkVolker Lendecke1-0/+4
(This used to be commit ce44158dde64cb65a3f51dfe1734f3c3d7f1bfd9)
2007-10-10r17333: Some C++ warningsVolker Lendecke1-4/+4
(This used to be commit be9aaffdaccae06c8c035eaf31862e34b7cfbe38)
2007-10-10r16650: Fix bug #3890 reported by jason@ncac.gwu.edu.Jeremy Allison1-3/+7
Jeremy. (This used to be commit 590b58cb507e5a6e459ff0c975beb9056336f233)
2007-10-10r16636: Fix bug #3884 reported by jason@ncac.gwu.eduJeremy Allison1-18/+9
Jeremy. (This used to be commit 7580eb947cdeb786be00efa5da727e32b28c99d6)
2007-10-10r16409: Fix Klocwork ID's.Volker Lendecke1-3/+21
1177 In reg_perfcount.c: 1200 1202 1203 1204 In regfio.c: 1243 1245 1246 1247 1251 Jerry, the reg_perfcount and regfio.c ones, can you take a look please? This is really your code, and I'm not sure I did the right thing to return an error. smbcacls.c: 1377 srv_eventlog_nt.c: 1415 1416 1417 srv_lsa_nt.c: 1420 1421 srv_netlog_nt.c: 1429 srv_samr_nt: 1458 1459 1460 Volker Volker (This used to be commit d6547d12b1c9f9454876665a5bdb010f46b9f5ff)
2007-10-10r15104: Implement Samba4's tdb_name().Volker Lendecke1-1/+1
Volker (This used to be commit d52002c1c9d28e637ca4d1553e800b0b97790f36)
2007-10-10r13978: Here is why it's essential to use SAFE_FREE instead of free.Jeremy Allison1-6/+6
If we use free(data.dptr) and then the subsequent tdb_open fails in _reg_perfcount_get_counter_data() then data.dptr is left as a non-zero pointer that has been freed. This would cause it to be reused later on. Coverity bug #162. Jeremy. (This used to be commit 053efc20981e0280c6af0ebb9e17cea07da85fe8)
2007-10-10r13915: Fixed a very interesting class of realloc() bugs found by Coverity.Jeremy Allison1-29/+13
realloc can return NULL in one of two cases - (1) the realloc failed, (2) realloc succeeded but the new size requested was zero, in which case this is identical to a free() call. The error paths dealing with these two cases should be different, but mostly weren't. Secondly the standard idiom for dealing with realloc when you know the new size is non-zero is the following : tmp = realloc(p, size); if (!tmp) { SAFE_FREE(p); return error; } else { p = tmp; } However, there were *many* *many* places in Samba where we were using the old (broken) idiom of : p = realloc(p, size) if (!p) { return error; } which will leak the memory pointed to by p on realloc fail. This commit (hopefully) fixes all these cases by moving to a standard idiom of : p = SMB_REALLOC(p, size) if (!p) { return error; } Where if the realloc returns null due to the realloc failing or size == 0 we *guarentee* that the storage pointed to by p has been freed. This allows me to remove a lot of code that was dealing with the standard (more verbose) method that required a tmp pointer. This is almost always what you want. When a realloc fails you never usually want the old memory, you want to free it and get into your error processing asap. For the 11 remaining cases where we really do need to keep the old pointer I have invented the new macro SMB_REALLOC_KEEP_OLD_ON_ERROR, which can be used as follows : tmp = SMB_REALLOC_KEEP_OLD_ON_ERROR(p, size); if (!tmp) { SAFE_FREE(p); return error; } else { p = tmp; } SMB_REALLOC_KEEP_OLD_ON_ERROR guarentees never to free the pointer p, even on size == 0 or realloc fail. All this is done by a hidden extra argument to Realloc(), BOOL free_old_on_error which is set appropriately by the SMB_REALLOC and SMB_REALLOC_KEEP_OLD_ON_ERROR macros (and their array counterparts). It remains to be seen what this will do to our Coverity bug count :-). Jeremy. (This used to be commit 1d710d06a214f3f1740e80e0bffd6aab44aac2b0)
2007-10-10r11579: syncing up perf counter code cfrom trunkGerald Carter1-41/+173
(This used to be commit 59c00924b67aa3d37a933731a56d03963ec7f1b5)
2007-10-10r11137: Compile with only 2 warnings (I'm still working on that code) on a gcc4Jeremy Allison1-2/+2
x86_64 box. Jeremy. (This used to be commit d720867a788c735e56d53d63265255830ec21208)
2007-10-10r10656: BIG merge from trunk. Features not copied overGerald Carter1-0/+1225
* \PIPE\unixinfo * winbindd's {group,alias}membership new functions * winbindd's lookupsids() functionality * swat (trunk changes to be reverted as per discussion with Deryck) (This used to be commit 939c3cb5d78e3a2236209b296aa8aba8bdce32d3)