1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-07 20:23:50 +03:00
Commit Graph

131 Commits

Author SHA1 Message Date
Andrew Tridgell
5921587ec2 r3323: more warning reductions 2007-10-10 13:04:55 -05:00
Jelmer Vernooij
2cfc8f24ce r3164: Look up ncalrpc identifiers using the EPMAPPER. ncalrpc now works nicely :-)
The various interface that support ncalrpc work nicely when tested
with smbtorture and ncalrpc.

Running RPC-SAMR against local smbd here is slightly faster using ncalrpc:
ncalrpc: 		1.8 sec
ncacn_ip_tcp:	1.9 sec
ncacn_np:		2.5 sec
2007-10-10 13:02:28 -05:00
Jelmer Vernooij
b3bc055ac7 r2914: ... and support enumerating values (data is not handled yet, only the names) 2007-10-10 12:59:47 -05:00
Jelmer Vernooij
5086d6b249 r2913: - Don't print hive name if it is NULL (regtree)
- Initialise hive name (reg_interface)
- Fix LDB backend (enumerating keys works now!)
2007-10-10 12:59:47 -05:00
Jelmer Vernooij
e7c256a92c r2911: Fix bug in opening relative keys 2007-10-10 12:59:47 -05:00
Jelmer Vernooij
4b5bf739f5 r2898: - Support enumerating remote registry values
- Some LDB updates
2007-10-10 12:59:45 -05:00
Jelmer Vernooij
f4860afc48 r2897: Fix double registration (of the registry subsystem) bug 2007-10-10 12:59:45 -05:00
Andrew Tridgell
814881f0e5 r2857: this commit gets rid of smb_ucs2_t, wpstring and fpstring, plus lots of associated functions.
The motivation for this change was to avoid having to convert to/from
ucs2 strings for so many operations. Doing that was slow, used many
static buffers, and was also incorrect as it didn't cope properly with
unicode codepoints above 65536 (which could not be represented
correctly as smb_ucs2_t chars)

The two core functions that allowed this change are next_codepoint()
and push_codepoint(). These functions allow you to correctly walk a
arbitrary multi-byte string a character at a time without converting
the whole string to ucs2.

While doing this cleanup I also fixed several ucs2 string handling
bugs. See the commit for details.

The following code (which counts the number of occuraces of 'c' in a
string) shows how to use the new interface:

size_t count_chars(const char *s, char c)
{
	size_t count = 0;

	while (*s) {
		size_t size;
		codepoint_t c2 = next_codepoint(s, &size);
		if (c2 == c) count++;
		s += size;
	}

	return count;
}
2007-10-10 12:59:39 -05:00
Stefan Metzmacher
d1e8b340a9 r2686: remove unused gtk+ check
metze
2007-10-10 12:59:22 -05:00
Andrew Tridgell
015db2ed8c r2672: don't call a variable "dup" as that conflicts with a standard system call name 2007-10-10 12:59:20 -05:00
Andrew Tridgell
8dc23821c9 r2671: we're getting too many errors caused by the talloc_realloc() API not
taking a context (so when you pass a NULL pointer you end up with
memory in a top level context). Fixed it by changing the API to take a
context. The context is only used if the pointer you are reallocing is
NULL.
2007-10-10 12:59:20 -05:00
Andrew Tridgell
c2be7b696c r2623: don't do pointer arithmetic on void*, as it doesn't work with non-GNU compilers 2007-10-10 12:59:13 -05:00
Jelmer Vernooij
2762ed3b9b r2518: Some long overdue changes:
- Samba4-style code in lib/registry (struct registry_key instead of REG_KEY, etc)
 - Use hives (like Windows has drives) instead of one root key (like a Unix FS)
 - usability fixes in the GTK utilities (autodetect the username,
	enable/disable options, etc)
 - fix gwsam compile
 - several bugfixes in the registry rpc code
 - do charset conversion in nt4 registry backend
2007-10-10 12:59:01 -05:00
Jelmer Vernooij
83f9f8eaa4 r2257: Tab completion support in regshell (complete command names and key names
in the current key)
2007-10-10 12:58:35 -05:00
Jelmer Vernooij
8056f4a9a7 r2254: Fix a couple of compiler warnings... 2007-10-10 12:58:35 -05:00
Andrew Bartlett
4294be4405 r1990: Fix breakage caused by the recent talloc changes. (Failure to process
an SPNEGO login from WinXP at least).

talloc_asprintf_append() lost an argument, but because TALLOC_CTX is
now a void*, this was not picked up by the compiler.

I've tested the login (asn1), but not the registry/gtk changes.

Andrew Bartlett
2007-10-10 12:58:15 -05:00
Andrew Tridgell
e35bb094c5 r1983: a completely new implementation of talloc
This version does the following:

  1) talloc_free(), talloc_realloc() and talloc_steal() lose their
     (redundent) first arguments

  2) you can use _any_ talloc pointer as a talloc context to allocate
     more memory. This allows you to create complex data structures
     where the top level structure is the logical parent of the next
     level down, and those are the parents of the level below
     that. Then destroy either the lot with a single talloc_free() or
     destroy any sub-part with a talloc_free() of that part

  3) you can name any pointer. Use talloc_named() which is just like
     talloc() but takes the printf style name argument as well as the
     parent context and the size.

The whole thing ends up being a very simple piece of code, although
some of the pointer walking gets hairy.

So far, I'm just using the new talloc() like the old one. The next
step is to actually take advantage of the new interface
properly. Expect some new commits soon that simplify some common
coding styles in samba4 by using the new talloc().
2007-10-10 12:58:14 -05:00
Volker Lendecke
5dc793b2b4 r1894: Convert // to /* */ 2007-10-10 12:58:09 -05:00
Jelmer Vernooij
d321cf20f1 r1432: - Move the various Gtk-specific parts from the registry code into a directory gtk/
- Move common "Samba-Gtk" code into gtk/common/ ("Connect to RPC pipe"-dialog, etc)
- Add a new utility 'gwcrontab' that can currently list, delete and add 'atsvc' jobs. It still displays times and dates as integers though, will fix that later.

Some screenshots available at:
 http://samba.org/~jelmer/gwcrontab/
2007-10-10 12:56:55 -05:00
Jelmer Vernooij
3af8419fa4 r1147: Support enumerating values 2007-10-10 12:56:41 -05:00
Jelmer Vernooij
971941acc7 r1119: Saner keyboard shortcuts 2007-10-10 12:56:38 -05:00
Jelmer Vernooij
456f97eed0 r1118: Read-only enumeration of keys in the LDB backend works now :-) 2007-10-10 12:56:38 -05:00
Andrew Tridgell
7c2279e4bc r1040: make sure main() doesn't get auto-prototyped 2007-10-10 12:56:33 -05:00
Jelmer Vernooij
7949dc25ab r1035: Support shared modules again 2007-10-10 12:56:31 -05:00
Jelmer Vernooij
db902bff3c r1032: Fix RPC backend segfault 2007-10-10 12:56:31 -05:00
Stefan Metzmacher
18062d2ed9 r960: convert 'unsigned int' to uint_t in the most places
metze
2007-10-10 12:56:23 -05:00
Stefan Metzmacher
72d9c70fdd r959: - a static WERROR function should return a WERROR:-)
- some minor format fixes

metze
2007-10-10 12:56:23 -05:00
Jelmer Vernooij
3df8ff6cf1 r955: Update debian package rules... builds now 2007-10-10 12:56:22 -05:00
Stefan Metzmacher
b5378803fd r943: change samba4 to use 'uint8_t' instead of 'unsigned char'
metze
2007-10-10 12:56:21 -05:00
Andrew Tridgell
66eb46dbb1 r893: a few more _t conversions 2007-10-10 12:56:18 -05:00
Stefan Metzmacher
2986c5f08c r890: convert samba4 to use [u]int8_t instead of [u]int8
metze
2007-10-10 12:56:16 -05:00
Stefan Metzmacher
0e5517d937 r884: convert samba4 to use [u]int32_t instead of [u]int32
metze
2007-10-10 12:56:15 -05:00
Andrew Tridgell
9a9244a1c6 r873: converted samba4 to use real 64 bit integers instead of
structures. This was suggested by metze recently.

I checked on the build farm and all the machines we have support 64
bit ints, and support the LL suffix for 64 bit constants. I suspect
some won't support strtoll() and related functions, so we will
probably need replacements for those.
2007-10-10 12:56:14 -05:00
Stefan Metzmacher
44de741038 r857: fix the build of gregedit (typo:-)
metze
2007-10-10 12:56:12 -05:00
Stefan Metzmacher
b556760146 r851: convert lib/registry/ to a config.mk file
metze
2007-10-10 12:56:12 -05:00
Jelmer Vernooij
fe5166ee88 r834: Fix gconf and dir backends 2007-10-10 12:53:54 -05:00
Jelmer Vernooij
e4f6ca8522 r833: Compile error 2007-10-10 12:53:54 -05:00
Jelmer Vernooij
9228aeeafd r832: Only show menu items for backends if they're present 2007-10-10 12:53:54 -05:00
Jelmer Vernooij
ad88561bec r830: Use pull_ucs2_talloc() instead of acnv_u2ux() and fix a memory leak. 2007-10-10 12:53:53 -05:00
Jelmer Vernooij
2a87981bd0 r829: Implement 'hive' command 2007-10-10 12:53:53 -05:00
Jelmer Vernooij
25c27b176c r828: Some fixes in the core and regshell concerning hives and
unicode
2007-10-10 12:53:53 -05:00
Jelmer Vernooij
8cd1b6bc70 r825: - Introduce support for multiple roots (or 'hives')
- Clean up rpc backend (possible now that multiple hives are supported)
2007-10-10 12:53:53 -05:00
Jelmer Vernooij
d4cc4b3d68 r819: Fix seg fault in rpc backend, found by Andrew Bartlett 2007-10-10 12:53:52 -05:00
Jelmer Vernooij
178cd902fc r734: Fix crash bug 2007-10-10 12:53:45 -05:00
Stefan Metzmacher
b6ac3021f2 r700: fix SMB_LIBRARY() to disable the lib by default
metze
2007-10-10 12:53:43 -05:00
Jelmer Vernooij
30d3915c76 r693: Make static 2007-10-10 12:53:43 -05:00
Jelmer Vernooij
0ace3bf289 r692: Add libwinregistry 2007-10-10 12:53:43 -05:00
Jelmer Vernooij
a63b704c36 r686: - Add SMB_EXT_LIB_FROM_PKGCONFIG()
- Build gregedit and registry_gconf again if the required libs are found (gconf and gtk)
2007-10-10 12:53:42 -05:00
Stefan Metzmacher
f7ded36699 r681: don't init r.out.result.v
metze
2007-10-10 12:53:41 -05:00
Stefan Metzmacher
5bbf0c2407 r673: disable registry_gconf for now
metze
2007-10-10 12:53:41 -05:00