summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* r13945: Move display_sec.c to lib/ (as suggested by Volker).Günther Deschner2007-10-102-4/+4
| | | | Guenther
* r13916: Fix Coverity bug #29. Looks like my code. I wonder how much there is ↵Volker Lendecke2007-10-101-0/+1
| | | | | | | | still lurking... Volker
* r13915: Fixed a very interesting class of realloc() bugs found by Coverity.Jeremy Allison2007-10-1055-481/+562
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* r13914: Fix Coverity bug #151.Volker Lendecke2007-10-101-1/+1
| | | | | | | I think this is actually a false warning, but as I've seen it with high gcc warning levels, lets fix it :-) Volker
* r13895: As agreed upon with gd on the phone, remove ↵Volker Lendecke2007-10-102-15/+3
| | | | | | | | | | WBFLAG_PAM_CONTACT_TRUSTDOM. This can not work for NTLM auth, where we only have a workstation account for our own domain. For the PAM Kerberos login we need to find a better way to do this, probably using Dsr_GetDCName and some winbind-crafted krb5.conf. Volker
* r13893: Fix for Coverity issue CID #164. The first one that I don'tJeremy Allison2007-10-101-0/+2
| | | | | think is a direct bug, but some code that needs clarification :-). Jeremy.
* r13892: Doh ! My bugfix had a bug :-). Spotted by Willi Mann <willi@wm1.at>,Jeremy Allison2007-10-101-2/+2
| | | | | if rrec can be null make sure we *never* deref it. Jeremy.
* r13889: Fix resource leak on error path. Coverity bug CID #73.Jeremy Allison2007-10-101-0/+1
| | | | Jeremy.
* r13887: Fix coverity bug CID #94. mem leak on error codepath.Jeremy Allison2007-10-101-0/+2
| | | | Jeremy.
* r13884: Fix coverity CID #95. Resource leak on error path.Jeremy Allison2007-10-101-0/+2
| | | | Jeremy.
* r13882: Fix coverity CID bug #96. Missing free on errorJeremy Allison2007-10-101-0/+1
| | | | | exit path. Jeremy.
* r13880: Fix coverity bug CID #97, mem leak on error path.Jeremy Allison2007-10-101-4/+4
| | | | Jeremy.
* r13878: move PORT_DATA_1 to use static sized UNICODE strings as per MSDNGerald Carter2007-10-103-29/+30
|
* r13875: Fix coverity bug #148. Deref of rrec before NULL check.Jeremy Allison2007-10-101-2/+7
| | | | Jeremy.
* r13873: I think this is the longstanding wins server crash bug, notJeremy Allison2007-10-101-17/+16
| | | | | | part of the changes I made but something that's been there a while.... Coverity bugid #41. Jeremy.
* r13864: Some cleanup and the samr set security object function client-side.Günther Deschner2007-10-107-140/+108
| | | | Guenther
* r13861: Avoid "net rpc join" segfaulting when storing the servername in theGünther Deschner2007-10-101-1/+1
| | | | | | affinity cache. Guenther
* r13846: Take care of system that do not have LDAP librariesSimo Sorce2007-10-101-0/+5
|
* r13843: Merge in net sam provision and some pdb_ldap fixesSimo Sorce2007-10-102-82/+516
|
* r13841: Fix an uninitialized variable warning.Volker Lendecke2007-10-101-1/+1
| | | | | | | Jerry, this just fixes the warning. This routine does not seem to cope well with !UNMARSHALLING. You might want to look... Volker
* r13829: From the "It's not pretty but it works" categoryGerald Carter2007-10-105-13/+244
| | | | | | | | | | * Finish prototype of the "add port command" implementation Format is "addportcommand portname deviceURI" * DeviceURI is either - socket://hostname:port/ - lpr://hostname/queue depending on what the client sent in the request
* r13824: * add api table for Xcv TCPMON and LOCALMON calls startingGerald Carter2007-10-103-15/+118
| | | | | | | with the "MonitorUI" call * Fix some parsing errors This gets us to the Add Port Wizard dialog.
* r13821: replacing some strings with macrosGerald Carter2007-10-101-9/+11
|
* r13820: * Start fleshing out the XcvDataPort() server implementationGerald Carter2007-10-103-40/+107
| | | | * Add support for the "Local Port" monitor as well through this API
* r13819: Remove accidently with rev 13713 submitted and never used MY_FLAGSLars Müller2007-10-101-1/+1
| | | | variable.
* r13816: Volunteering :-)Volker Lendecke2007-10-104-23/+23
| | | | | | | | | | | | | > for the svn log: > > - Solaris' /bin/sh doesn't know "test -e" - let's use "test -f" instead > > Some volunteer wanna check this in? :) > > Cheers > Bjoern Volker
* r13815: "Into the blind world let us now descend,"Gerald Carter2007-10-106-138/+161
| | | | | | | | | | | | | | | | Began the poet, his face as pale as death. "I will go first, and you will follow me." --- Adding XcvDataPort() to the spoolss code for remotely add ports. The design is to allow an intuitive means of creating a new CUPS print queue from the Windows 2000/XP APW without hacks like specifying the deviceURI in the location field of the printer properties dialog. Also set 'default devmode = yes' as the new default since it causes no harm and only is executed when you have a NULL devmode anyways.
* r13802: I *knew* ASU on sparc had to be good for *something* ! :-).Jeremy Allison2007-10-102-5/+5
| | | | | | Fix incorrect size understanding of sid name type (yes it's already correct in the Samba4 IDL :-). Jeremy.
* r13799: Make locktest debug a little easier to read.Jeremy Allison2007-10-101-3/+17
| | | | Jeremy.
* r13796: Another load_case_tables...Jeremy Allison2007-10-101-0/+2
| | | | Jeremy.
* r13794: If you are going to go, go big. That's what I always say.Gerald Carter2007-10-101-2/+2
| | | | | * disable winbind enum {users,groups} by default after further conversations with Volker.
* r13792: Merged Simo's fixes for tdbtraverse.Jeremy Allison2007-10-101-2/+2
| | | | Jeremy.
* r13791: Having S-1-1-0 show up in winbind lookupsid does not really make sense.Volker Lendecke2007-10-102-3/+18
| | | | Volker
* r13778: When deleting machine accounts it's the SeMachineAccountPrivilegeJeremy Allison2007-10-101-1/+9
| | | | | that counts. Jeremy.
* r13776: Merge in the editposix ldapsam optimizationSimo Sorce2007-10-102-109/+892
|
* r13772: More default changesGerald Carter2007-10-101-2/+3
| | | | | | * winbind nested groups = yes * host msdfs = ye * msdfs root = yes
* r13771: BUG 3534: ignore lines in the username map file with no right hand ↵Gerald Carter2007-10-101-2/+4
| | | | list rather than bailing out
* r13766: Patch from Arek Glabek <aglabek@centeris.com>:Gerald Carter2007-10-101-6/+3
| | | | | * Fix parsing error in eventlogadm caused by log entries with no DAT: line.
* r13765: Fix bug reported by jra. Don't check for a group SID when storingGerald Carter2007-10-101-0/+2
| | | | a user since we no longer pay any attention to the value.
* r13763: r13223@cabra: derrell | 2006-02-28 20:48:23 -0500Derrell Lipman2007-10-101-1/+5
| | | | Add the missing comment about needing to save the new share name.
* r13761: r13221@cabra: derrell | 2006-02-28 20:40:56 -0500Derrell Lipman2007-10-101-0/+11
| | | | | | When only allowing one connection per server, the cache needs to track which share is currently connected, or we never know whether a tdis()/tcon() for the new share is required.
* r13759: As pointed out by Volker, it isn't much good creatingJeremy Allison2007-10-101-0/+15
| | | | | | a new empty acl in remove_posix_acl if you don't bother to set it on the file in question :-). Jeremy.
* r13756: use samu_new() rather than calling talloc() directly.Gerald Carter2007-10-101-1/+1
|
* r13751: Call proto_exists before we create the precompiles headers.Lars Müller2007-10-101-1/+1
|
* r13750: Cleanup line wrap to less than 80 chars.Lars Müller2007-10-101-3/+4
|
* r13748: Don't reference memory after we just freed it (Doh!).Jeremy Allison2007-10-101-2/+3
| | | | | | Thanks to tridge's changes to the directory delete on close tests for catching this. Jeremy.
* r13747: Fix the reference count for tdbsam_open() - on anJeremy Allison2007-10-101-5/+9
| | | | | | | | | upgrade it calls tdbsam_convert() which calls tdbsam_open() deep inside the init_sam_from_buffer_vX call. If the ref count hasn't been set yet then we will close the tdbsam reference in tdbsam_getsampwsid(). smbpasswd -a was core-dumping again :-). Jeremy
* r13736: Don't assume that printf can handle string arguments being NULL. TidyJames Peach2007-10-101-14/+17
| | | | up typing and tighten error checking a little.
* r13733: Reorder so that locking and params declarations are not mingled.James Peach2007-10-101-17/+18
|
* r13729: Fix smbpasswd -xVolker Lendecke2007-10-101-13/+6
|