1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

437 Commits

Author SHA1 Message Date
Volker Lendecke
caf8c6a76b r21064: The core of this patch is
void message_register(int msg_type,
                      void (*fn)(int msg_type, struct process_id pid,
-                                void *buf, size_t len))
+                                void *buf, size_t len,
+                                void *private_data),
+                     void *private_data)
 {
        struct dispatch_fns *dfn;

So this adds a (so far unused) private pointer that is passed from
message_register to the message handler. A prerequisite to implement a tiny
samba4-API compatible wrapper around our messaging system. That itself is
necessary for the Samba4 notify system.

Yes, I know, I could import the whole Samba4 messaging system, but I want to
do it step by step and I think getting notify in is more important in this
step.

Volker
(This used to be commit c8ae60ed65)
2007-10-10 12:17:32 -05:00
James Peach
9a02736348 r19626: Coalesce usage of DUMP_CORE. Fix formatting on chdir error message
in core dump path.
(This used to be commit 9a51fba71c)
2007-10-10 12:15:42 -05:00
Jim McDonough
b449884661 r18660: Fix build, one uuid->GUID was missed.
(This used to be commit f8ea2069d4)
2007-10-10 11:52:20 -05:00
Stefan Metzmacher
258a465e20 r18605: sync dlinklist.h with samba4, that means DLIST_ADD_END()
and DLIST_DEMOTE() now take the type of the tmp pointer
not the tmp pointer itself anymore.

metze
(This used to be commit 2f58645b70)
2007-10-10 11:51:59 -05:00
Jeremy Allison
6f9ce7def7 r17864: Fix possible null deref if client doesn't give us
an answer record. Found by the Stanford checker.
Jeremy.
(This used to be commit 1ec77c5011)
2007-10-10 11:38:55 -05:00
Volker Lendecke
22c7238825 r17807: Fix a file descriptor leak pointed out by John Malmberg. Thanks!
Volker
(This used to be commit fac007ccbe)
2007-10-10 11:38:49 -05:00
Jeremy Allison
e7a49f2b25 r17668: Fix the miscalculations in pushing announces. Fixes
problems Kukks reported.
Jeremy.
(This used to be commit 426d722029)
2007-10-10 11:38:45 -05:00
Volker Lendecke
f852fdbe06 r17626: Some C++ Warnings
(This used to be commit 09e7c010f0)
2007-10-10 11:38:44 -05:00
Volker Lendecke
b29915d611 r17571: Change the return code of cli_session_setup from BOOL to NTSTATUS
Volker
(This used to be commit 94817a8ef5)
2007-10-10 11:38:39 -05:00
Jeremy Allison
fbdcf2663b r16945: Sync trunk -> 3.0 for 3.0.24 code. Still need
to do the upper layer directories but this is what
everyone is waiting for....

Jeremy.
(This used to be commit 9dafb7f48c)
2007-10-10 11:19:14 -05:00
Jeremy Allison
d88926f6b4 r16665: Fix a couple of bugs I discovered now I've looked
closer at the wins server code. Firstly, it needs
to do the searches on the SELF_NAMES correctly,
secondly it needs to flush the in-memory cache
out before returning the 1b names - else it might
get duplicates returned if many 1b queries are
done in quick succession. Jerry, I hate to say
this but you might want to consider this for 3.0.23....
Jeremy.
(This used to be commit b36b9befbb)
2007-10-10 11:19:07 -05:00
Jeremy Allison
79eaa709a0 r16642: Fix show-stopper bug #3876. Double-free in wins
server code. Jerry please merge for 3.0.23.
Jeremy.
(This used to be commit d354b430ff)
2007-10-10 11:19:05 -05:00
Jeremy Allison
5a1a08d428 r16581: Fix Klocwork #2017. Possible null deref.
Jeremy.
(This used to be commit 6967fd4cef)
2007-10-10 11:19:01 -05:00
Jeremy Allison
d70803ebe3 r16579: Fix Klocwork #2016. Possible null deref.
Jeremy.
(This used to be commit f6d5bae4a1)
2007-10-10 11:19:01 -05:00
Jeremy Allison
9a7adde8a3 r16576: Fix Klocwork #2015. Possible null deref.
Jeremy.
(This used to be commit 9cbfaf62a3)
2007-10-10 11:19:01 -05:00
Jeremy Allison
4433376361 r16313: Not a problem - but ensure Klocwork is quiet (#872).
Jeremy.
(This used to be commit 22a345deed)
2007-10-10 11:17:33 -05:00
Jeremy Allison
a1e0a0e928 r16230: Fix Klocwork #861 and others. localtime and asctime
can return NULL. Ensure we check all returns correctly.
Jeremy.
(This used to be commit 6c61dc8ed6)
2007-10-10 11:17:26 -05:00
Jeremy Allison
a5da0a72e1 r16213: Fix Klocwork #852. iface_n_ip can potentially
return NULL. Ensure we don't deref.
Jeremy.
(This used to be commit c2f0ea2ff2)
2007-10-10 11:17:26 -05:00
Jeremy Allison
863aa313c1 r16019: This should not be a level zero message - it's harmless
and can happen though misconfiguration.
Jeremy.
(This used to be commit 4b9cf399a6)
2007-10-10 11:17:18 -05:00
Jeremy Allison
0648638fef r15700: Make nmbd udp sockets non-blocking to prevent problem
with select returning true but no data being available.
Fix for bug #3779.
Jeremy.
(This used to be commit e5787cf75b)
2007-10-10 11:17:08 -05:00
Volker Lendecke
ce5f1afc75 r15483: Fix 'declaration after code' warnings.
Volker
(This used to be commit 7729799be9)
2007-10-10 11:16:54 -05:00
James Peach
4d55a81958 r15450: Change profiling data macros to use stack variables rather than
globals. This catches mismatched start/end calls and removes
the need for special nested profiling calls.
(This used to be commit ee75049881)
2007-10-10 11:16:47 -05:00
Jeremy Allison
0f985dcb19 r15012: Fix bug #2715. Fix suggested by ISHIKAWA Tomonori <toishika@fsi.co.jp>
No need to null terminate early, pull_ascii_fstring will do this.
Jeremy.
(This used to be commit b1bbe56831)
2007-10-10 11:15:56 -05:00
James Peach
4fa5559800 r14898: This change is an attempt to improve the quality of the information that
is produced when a process exits abnormally.

First, we coalesce the core dumping code so that we greatly improve our
odds of being able to produce a core file, even in the case of a memory
fault. I've removed duplicates of dump_core() and split it in two to
reduce the amount of work needed to actually do the dump.

Second, we refactor the exit_server code path to always log an explanation
and a stack trace. My goal is to always produce enough log information
for us to be able to explain any server exit, though there is a risk
that this could produce too much log information on a flaky network.

Finally, smbcontrol has gained a smbd fault injection operation to test
the changes above. This is only enabled for developer builds.
(This used to be commit 56bc02d644)
2007-10-10 11:15:53 -05:00
Stefan Metzmacher
250c02554e r14618: add --no-process-group to all server programms
to make the following possible:

timelimit 20000 bin/nmbd -F -S --no-process-group
timelimit 20000 bin/smbd -F -S --no-process-group

this is needed to 'make test' working without losing child processes

metze
(This used to be commit c3a9f30e2a)
2007-10-10 11:15:39 -05:00
Jeremy Allison
6b35642037 r14007: Coverity bug CID #197. Don't compare against 0, we
mean the ttl instead.
Jeremy.
(This used to be commit ccb2a52e29)
2007-10-10 11:11:04 -05:00
Jeremy Allison
6d9c2b872f r13892: Doh ! My bugfix had a bug :-). Spotted by Willi Mann <willi@wm1.at>,
if rrec can be null make sure we *never* deref it.
Jeremy.
(This used to be commit d6d7a5ac62)
2007-10-10 11:10:58 -05:00
Jeremy Allison
4d79117c6d r13887: Fix coverity bug CID #94. mem leak on error codepath.
Jeremy.
(This used to be commit dd47e0ef11)
2007-10-10 11:10:58 -05:00
Jeremy Allison
4c0bf8d75d r13884: Fix coverity CID #95. Resource leak on error path.
Jeremy.
(This used to be commit f4bf550b57)
2007-10-10 11:10:58 -05:00
Jeremy Allison
9bb215fe68 r13882: Fix coverity CID bug #96. Missing free on error
exit path.
Jeremy.
(This used to be commit 95ef857c89)
2007-10-10 11:10:58 -05:00
Jeremy Allison
cc6b2d086a r13880: Fix coverity bug CID #97, mem leak on error path.
Jeremy.
(This used to be commit 0dc37dd2d8)
2007-10-10 11:10:58 -05:00
Jeremy Allison
fa94300f5f r13875: Fix coverity bug #148. Deref of rrec before NULL check.
Jeremy.
(This used to be commit 0f1dffb2f2)
2007-10-10 11:10:57 -05:00
Jeremy Allison
0a516662ab r13873: I think this is the longstanding wins server crash bug, not
part of the changes I made but something that's been there
a while.... Coverity bugid #41.
Jeremy.
(This used to be commit 2f6cf810ea)
2007-10-10 11:10:57 -05:00
Gerald Carter
fb5362c069 r13571: Replace all calls to talloc_free() with thye TALLOC_FREE()
macro which sets the freed pointer to NULL.
(This used to be commit b65be8874a)
2007-10-10 11:10:14 -05:00
Gerald Carter
fbe02a6021 r13510: plug memory leak in WINS server code.
(This used to be commit 381c327a65)
2007-10-10 11:10:08 -05:00
Derrell Lipman
9c15bd311d r13212: r12414@cabra: derrell | 2006-01-28 17:52:17 -0500
lp_load() could not be called multiple times to modify parameter settings based
 on reading from multiple configuration settings.  Each time, it initialized all
 of the settings back to their defaults before reading the specified
 configuration file.

 This patch adds a parameter to lp_load() specifying whether the settings should
 be initialized.  It does, however, still force the settings to be initialized
 the first time, even if the request was to not initialize them.  (Not doing so
 could wreak havoc due to uninitialized values.)
(This used to be commit f2a24de769)
2007-10-10 11:06:18 -05:00
Gerald Carter
e95e6044b0 r13081: correct fix for the segv in nmbd caused by a double free on namerec.
(This used to be commit c908dbc4b2)
2007-10-10 11:06:12 -05:00
Gerald Carter
f751954009 r12967: BUG 1061: don't corrupt the file name when reading an lmhosts file (-H) in nmbd. Patch from Andrew Esh <Andrew_Esh@adaptec.com>
(This used to be commit 14160c4961)
2007-10-10 11:06:09 -05:00
Gerald Carter
4c7b4cd33a r12946: fix a segfault in nmbd when 'wins support = yes' caused by double free
(This used to be commit c11372f4ec)
2007-10-10 11:06:08 -05:00
Jeremy Allison
496b678882 r12564: Ensure load_case_tables is always done first.
Jeremy.
(This used to be commit addb509529)
2007-10-10 11:05:59 -05:00
Jeremy Allison
4d3152e145 r12214: Fix compile if SYNC_DNS is set.
Jeremy.
(This used to be commit 7c545e1e77)
2007-10-10 11:05:49 -05:00
Jeremy Allison
83b987befd r12107: Move to a tdb-based wins database. At the moment we still
use it as though it were an in-memory db and dump out to
a flat file every 2 mins, but that can now change.
Jeremy.
(This used to be commit a342681792)
2007-10-10 11:05:45 -05:00
Jeremy Allison
d1f91f7c72 r12043: It's amazing the warnings you find when compiling on a 64-bit
box with gcc4 and -O6...
Fix a bunch of C99 dereferencing type-punned pointer will break
strict-aliasing rules errors. Also added prs_int32 (not uint32...)
as it's needed in one place. Find places where prs_uint32 was being
used to marshall/unmarshall a time_t (a big no no on 64-bits).
More warning fixes to come.
Thanks to Volker for nudging me to compile like this.
Jeremy.
(This used to be commit c65b752604)
2007-10-10 11:05:42 -05:00
Jeremy Allison
c3d673e571 r11566: From metze. Use "interpret_addr(lp_socket_address())" for port 138.
Jeremy.
(This used to be commit d398a1aeb4)
2007-10-10 11:05:20 -05:00
Jeremy Allison
6d5757395a r11511: A classic "friday night check-in" :-). This moves much
of the Samba4 timezone handling code back into Samba3.
Gets rid of "kludge-gmt" and removes the effectiveness
of the parameter "time offset" (I can add this back
in very easily if needed) - it's no longer being
looked at. I'm hoping this will fix the problems people
have been having with DST transitions. I'll start comprehensive
testing tomorrow, but for now all modifications are done.
Splits time get/set functions into srv_XXX and cli_XXX
as they need to look at different timezone offsets.
Get rid of much of the "efficiency" cruft that was
added to Samba back in the day when the C library
timezone handling functions were slow.
Jeremy.
(This used to be commit 414303bc02)
2007-10-10 11:05:19 -05:00
Gerald Carter
8ec32e008a r10822: updating copyright info
(This used to be commit ef3845366b)
2007-10-10 11:04:55 -05:00
Gerald Carter
54abd2aa66 r10656: BIG merge from trunk. Features not copied over
* \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 939c3cb5d7)
2007-10-10 11:04:48 -05:00
Gerald Carter
2f626e7b5a r9790: remove 'set but not used' variables (reported by Jason Mader)
(This used to be commit 9c78f3b0d6)
2007-10-10 11:03:26 -05:00
Tim Potter
311cf22a2e r8946: Some casts to fix warnings when time_t is an unsigned type. Fixes
bugzilla #1888 and #1894.
(This used to be commit dcc7437138)
2007-10-10 11:00:22 -05:00
Gerald Carter
129b461673 r7440: * merge registry server changes from trunk (so far) for more
printmig.exe work
* merge the sys_select_signal(char c) change from trunk
  in order to keeo the winbind code in sync
(This used to be commit a112c5570a)
2007-10-10 10:57:09 -05:00