Age | Commit message (Collapse) | Author | Files | Lines |
|
(This used to be commit 0dc3030bce7bc7a58c509c70fe503a70db80b62d)
|
|
(This used to be commit e9a63e3b35822eefbc5e17b6f9a4aab5e8c03074)
|
|
Jeremy.
(This used to be commit e3a28bf4c8064f7053b7d1a25a2f087ac2095fcd)
|
|
can't have an uninitialized *returned val.
Jeremy.
(This used to be commit e83515afd2cb63b0dfa4f7fe00b6b7163bf35f2f)
|
|
on pipe initialization failure.
Jeremy.
(This used to be commit daa919a94b3d81401654004bc0f32c45451203c1)
|
|
Jeremy.
(This used to be commit d993797191865878ebfd2ff9028d341017605cd6)
|
|
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)
|
|
(This used to be commit c803e1b2afdfc5bd983f046c976c01adebcfa1ad)
|
|
* 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
(This used to be commit 6d74de7a676b71e83a3c3714743e6380c04e4425)
|
|
with the "MonitorUI" call
* Fix some parsing errors
This gets us to the Add Port Wizard dialog.
(This used to be commit a444aa7f0088fb71ff89df8c280209188b33ec3d)
|
|
(This used to be commit a34ab5c827630a5517e4c706877a172e6063f227)
|
|
* Add support for the "Local Port" monitor as well through this API
(This used to be commit ba9cdd88a0abf90a9c04959e554d7e4f10d17ff7)
|
|
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.
(This used to be commit 123e478ce5b5f63a61d00197332b847e83722468)
|
|
that counts.
Jeremy.
(This used to be commit aa85ba4f3799ffbe5c6f84f768f03a4c68d879dc)
|
|
* Fix parsing error in eventlogadm caused by log entries
with no DAT: line.
(This used to be commit f0a8f438793a806e8cf73e1e695b09e540a4239e)
|
|
removed, I presume by mistake, by Jerry in the recent
patch the removes the primary group SID stuff.
set_user_info_21 is called to update many other things
like the description of a user for example (that's what
failed on me).
Jerry, please review this one.
(This used to be commit 239a37d201168d095f600042b1ffcd047f18ba8a)
|
|
* Fix a couple of related parsing issues.
* in the info3 reply in a samlogon, return the ACB-flags (instead of
returning zero)
Guenther
(This used to be commit 5b89e8bc24f0fdc8b52d5c9e849aba723df34ea7)
|
|
* ignore the primary group SID attribute from struct samu*
* generate the primary group SID strictlky from the Unix
primary group when dealing with passdb users
* Fix memory leak in original patch caused by failing to free a
talloc *
* add wrapper around samu_set_unix() to prevent exposing the create
BOOL to callers. Wrappers are samu_set_unix() and samu-allic_rid_unix()
(This used to be commit bcf269e2ec6630b78d909010fabd3b69dd6dda84)
|
|
"rename user script" to do the rename of the posix machine account (this
might be changed later). Fixes #2331.
Guenther
(This used to be commit b2eac2e6eb6ddd1bcb4ed5172e7cd64144c18d16)
|
|
* replace all pdb_{init,fill}_sam_pw() calls with samu_set_unix()
(This used to be commit 6f1afa4acc93a07d0ee9940822d7715acaae634f)
|
|
to make full use of the new talloc() interface. Discussed with Volker
and Jeremy.
* remove the internal mem_ctx and simply use the talloc()
structure as the context.
* replace the internal free_fn() with a talloc_destructor() function
* remove the unnecessary private nested structure
* rename SAM_ACCOUNT to 'struct samu' to indicate the current an
upcoming changes. Groups will most likely be replaced with a
'struct samg' in the future.
Note that there are now passbd API changes. And for the most
part, the wrapper functions remain the same.
While this code has been tested on tdb and ldap based Samba PDC's
as well as Samba member servers, there are probably still
some bugs. The code also needs more testing under valgrind to
ensure it's not leaking memory.
But it's a start......
(This used to be commit 19b7593972480540283c5bf02c02e5ecd8d2c3f0)
|
|
macro which sets the freed pointer to NULL.
(This used to be commit b65be8874a2efe5a4b167448960a4fcf6bd995e2)
|
|
the correct part of the netlogon and schannel packets.
Jeremy.
(This used to be commit 4877f336b257e6f59833a6e0679959a2ec879974)
|
|
by schannel if "server schannel = true" was set.
Jeremy.
(This used to be commit fd84d9703ed01feb010df4ebb7e9ceb0d063780b)
|
|
Jeremy.
(This used to be commit ea82958349a57ef4b7ce9638eec5f1388b0fba2a)
|
|
creds under all circumstances. This may be wrong, but
at least we're now consistent.
Jeremy.
(This used to be commit 09f0b3e1a366ba3eef4ab9a8e302daabd4f36936)
|
|
for the creds store. This should fix the problems
Jerry reported (but I have still to run tests :-).
Jeremy.
(This used to be commit 43f095a38d66caa774d80fe32e1b96ec25dd1f07)
|
|
code relied upon file permissions alone. Now we check that
the user is a printer administrator and that the share has not been
marked read only for that user.
(This used to be commit 117d9fd9e16a7afbc6772506a4f8c33ff99d33f7)
|
|
(This used to be commit a95d7d722273863efa820674672393fe6e5a33b7)
|
|
Bartlett's
Samba4 code.
Jeremy.
(This used to be commit a2fb436fc5dd536cfe860be93f55f9cb58139a0e)
|
|
Jeremy.
(This used to be commit 6ec0e9124a1a7b19c9853b8e26075cbbb8751f10)
|
|
I mean it this time :-).
Jeremy.
(This used to be commit 80f4868944d349015d2b64c2414b06466a8194aa)
|
|
Make sure to associate the DOMAIN dispinfo cache
with a User/Group SAMR handle (not the SID of the user or group).
Ensure that enumeration after deleting a user works.
(This used to be commit 7967f89caa17ea93cb7e9d8695f1904ccb9a2864)
|
|
Volker
(This used to be commit bb40e544de68f01a6e774753f508e69373b39899)
|
|
Jeremy.
(This used to be commit f1a362580ae37730dc8393a79f832aed5d0ea4be)
|
|
Jeremy.
(This used to be commit b57406c89feaf550f6c2d29ef0ed73a935908add)
|
|
Jeremy.
(This used to be commit 2274709587bd1f27bea2eacf633182f20cd07b1e)
|
|
Jeremy.
(This used to be commit a9e1d0f3b4fd7a0732a5023d0b4dcc2c4b1b03f8)
|
|
Jeremy.
(This used to be commit a164cfab420a2439dad8fd85f8b4d652087fa6b9)
|
|
Guenther
(This used to be commit 58baf718be90d750f51cf51a25714fcdcd5679b7)
|
|
Guenther
(This used to be commit f60eddc0a4dfe623e5f115533a62c03810fd5f38)
|
|
Jeremy.
(This used to be commit 9437ffc84f4d924ab67f3e16ef507d2aeeeb5f34)
|
|
Jeremy
(This used to be commit f58d0ebf749ad6dab562e74e9fd2c16606183d6c)
|
|
Jeremy.
(This used to be commit 58544eb3c848e1dddd774270fbaae7d704a37b53)
|
|
makes fixes much easier to port. Fix the size of dc->sess_key to
be 16 bytes, not 8 bytes - only store 8 bytes in the inter-smbd
store in secrets.tdb though. Should fix some uses of the dc->sess_key
where we where assuming we could read 16 bytes.
Jeremy.
(This used to be commit 5b3c2e63c73fee8949108abe19ac7a448a033a7f)
|
|
Jeremy.
(This used to be commit 8ae70122b79fbe682c227ec2c4e5a72bf58d76de)
|
|
from Samba4 on how to decode the 532 byte password buffers.
Getting closer to passing samba4 RPC-SCHANNEL test.
Jeremy.
(This used to be commit 205db6968a26c43dec64c14d8053d8e66807086f)
|
|
internally in services_db.c now. This prevents internal services from
being listed twice (one internal and one external) when no
'svcctl list' parameter is explcitly set in smb.conf
(This used to be commit 6c4ede6cee7e1d25a6357e959972e8d390c27fe3)
|
|
Sync with trunk as off r13315
(This used to be commit 17e63ac4ed8325c0d44fe62b2442449f3298559f)
|
|
by saving the UNIX token used to set a delete on close flag,
and using it when doing the delete. libsmbsharemodes.so still
needs updating to cope with this change.
Samba4 torture tests to follow.
Jeremy.
(This used to be commit 23f16cbc2e8cde97c486831e26bcafd4ab4a9654)
|