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

623 Commits

Author SHA1 Message Date
Volker Lendecke
ff7b6e52b5 r18402: Comment and (hopefully) fix remote command completion for smbclient.
Fix Bug ID 4084.

Volker
(This used to be commit 0baa3fcfa6)
2007-10-10 11:51:22 -05:00
Volker Lendecke
f8a17bd8bd r18047: More C++ stuff
(This used to be commit 86f4ca84f2)
2007-10-10 11:43:24 -05:00
Volker Lendecke
5196825b4c r17850: Another dummy checkin for the build farm to retry
(This used to be commit ac7087a651)
2007-10-10 11:38:53 -05:00
Jeremy Allison
a64925ddff r17800: Start using struct timespec internally for file times
on the wire. This allows us to go to nsec resolution
for systems that support it. It should also now be
easy to add a correct "create time" (birth time)
for systems that support it (*BSD). I'll be watching
the build farm closely after this one for breakage :-).
Jeremy.
(This used to be commit 425280a1d2)
2007-10-10 11:38:48 -05:00
Volker Lendecke
0b56ff1ea3 r17605: Some C++ warnings
(This used to be commit 05268d7a73)
2007-10-10 11:38:42 -05:00
Volker Lendecke
69bbc374b1 r17572: Fix the build
(This used to be commit acf237b3cd)
2007-10-10 11:38:40 -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
4ef1f8e425 r16971: Ensure we use the correct separator for pathnames
in POSIX mode (clitar needs fixing too). Add test
posix lock/unlock commands.
Jeremy.
(This used to be commit 596497ccc2)
2007-10-10 11:19:16 -05:00
Jeremy Allison
760671b0e2 r16962: Add a few utility fns into client. Allow POSIX capabilities
to be selected.
Jeremy.
(This used to be commit 2d8d4bd77b)
2007-10-10 11:19:16 -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
c1dbb16945 r16608: Klocwork #2035. Null deref (bit of a stretch... :-).
Jeremy.
(This used to be commit 7d7a98208b)
2007-10-10 11:19:03 -05:00
Jeremy Allison
67af7a8c43 r16587: Fix Klocwork #1987. Memleak on reusing x_dbf.
Jeremy.
(This used to be commit 16b0617cb0)
2007-10-10 11:19:01 -05:00
Volker Lendecke
e7fc37cf0f r16360: Fix Klocwork ID 136 520 521 522 523 542 574 575 576 607
in net_rpc.c: 715 716 732 734 735 736 737 738 739 749

in net_rpc_audit.c: 754 755 756

in net_rpc_join.c: 757

in net_rpc_registry: 766 767

in net_rpc_samsync.c: 771 773

in net_sam.c: 797 798

Volker
(This used to be commit 3df0bf7d60)
2007-10-10 11:18:48 -05:00
Volker Lendecke
ec49dff326 r16338: Fix Klocwork ID 150
(This used to be commit ded2952e00)
2007-10-10 11:17:36 -05:00
James Peach
06491a4cb1 r16274: Fix the smbclient prompting behaviour for both systems that have
libreadline and those that don't. We always use the built-in readline
replacement for non-interactive mode. Interactive prompts are always
emitted to stdout and non-interactive mode never prompts at all.

Introduce x_fdup to avoid spuriously closing stdout when a logfile is
specified on the command line and setup_logging is called a second time.
(This used to be commit 848ac756f6)
2007-10-10 11:17:30 -05:00
Volker Lendecke
d93b408678 r16251: for i in seq 1 1000
do
	echo "I will always compile before commit :-)"
done

Also fix Klokwork ID 806.

Volker
(This used to be commit 4974c598c0)
2007-10-10 11:17:28 -05:00
Volker Lendecke
05f59b2c34 r16250: Fix Klokwork IDs 148, 151, 152, 154.
Volker
(This used to be commit d7a75ee94d)
2007-10-10 11:17:28 -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
Günther Deschner
f5e79ae825 r15552: Fix segfault...
Guenther
(This used to be commit ff93fc7c1e)
2007-10-10 11:16:58 -05:00
Günther Deschner
767ac75e6b r15519: Fix segfault.
Guenther
(This used to be commit a0548914c2)
2007-10-10 11:16:55 -05:00
James Peach
584ac985ec r15448: New autoconf macro to test for sysconf variables.
(This used to be commit a19d4f2bb4)
2007-10-10 11:16:46 -05:00
Jeremy Allison
2ebcc2933a r15141: Fix for #3592 inspired by Justin Best <justinb@pdxmission.org>.
Ignore a file in a tar output if the first read fails. Also
cope with <2GB read fail.
Jeremy.
(This used to be commit 1b73e699e1)
2007-10-10 11:16:26 -05:00
Volker Lendecke
76a2ac3ac3 r15098: Make smbclient -L use RPC to list shares, fall back to RAP. This should list
long share names.

Volker
(This used to be commit d3d388180d)
2007-10-10 11:16:23 -05:00
Jeremy Allison
c1bcddd803 r14359: Try and fix Coverity #176 by making the pointer
aliasing clearer. This isn't a bug but a code
clarification.
Jeremy.
(This used to be commit a3b8bee3ff)
2007-10-10 11:15:26 -05:00
Jeremy Allison
8f96b1bf0f r14351: Ensure we use the minimum of PATH_MAX and sizeof(pstring).
Fix Coverity #59.
Jeremy.
(This used to be commit d793e1550c)
2007-10-10 11:15:26 -05:00
Volker Lendecke
b84029452b r14248: Fix Coverity bug # 84
(This used to be commit 811ae2b21f)
2007-10-10 11:15:20 -05:00
Volker Lendecke
0837f6b584 r14246: Fix Coverity bug # 85
(This used to be commit ebc21336d8)
2007-10-10 11:15:20 -05:00
Volker Lendecke
1c66bcef8d r14242: Fix Coverity bug # 82
(This used to be commit 9f645e9962)
2007-10-10 11:15:19 -05:00
Jeremy Allison
ab43bf3e10 r14176: Fix coverity bug #30. Ensure no possible null deref.
Jeremy.
(This used to be commit e5d6069cf8)
2007-10-10 11:15:15 -05:00
Jeremy Allison
1b3e1f9b7c r14166: Fix const warning.
Jeremy.
(This used to be commit 2ec461ae58)
2007-10-10 11:15:14 -05:00
Günther Deschner
14e904fe86 r14148: Removing the not very well tested krb5 ticket refresh handling activated
over --with-kcm. No time to look after it for the moment.

Guenther
(This used to be commit 7ec2b31a87)
2007-10-10 11:15:13 -05:00
Günther Deschner
e724dc9a60 r14145: Add missing WITH_KCM hunks from my local tree.
Guenther
(This used to be commit 977079a058)
2007-10-10 11:15:13 -05:00
Steve French
58752bccdd r14128: Remove warning generated by coverity scan tool (missing SAFE_FREE in error path)
(This used to be commit 33a1e26114)
2007-10-10 11:11:14 -05:00
Steve French
f3b39786db r14127: Remove coverity warning on mount.cifs.c
(This used to be commit 2ec51635ae)
2007-10-10 11:11:13 -05:00
Steve French
84c398a72e r14126: resolve two warnings from the coverity scan
(This used to be commit 32c7243b80)
2007-10-10 11:11:13 -05:00
Jeremy Allison
9e65a2cb98 r14009: Remove last const warning (have to use CONST_DISCARD).
Jeremy.
(This used to be commit af0ade470f)
2007-10-10 11:11:05 -05:00
Jeremy Allison
26c95f3545 r14006: Fix a couple of irritating warnings.
Jeremy.
(This used to be commit ead13ca522)
2007-10-10 11:11:04 -05:00
Jeremy Allison
894358a8f3 r13915: Fixed a very interesting class of realloc() bugs found by Coverity.
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 1d710d06a2)
2007-10-10 11:10:59 -05:00
Lars Müller
1006c89e1b r13714: Set MOUNT_CIFS_VENDOR_SUFFIX if _SAMBA_BUILD_ is set to
"-"SAMBA_VERSION_OFFICIAL_STRING"-"SAMBA_VERSION_VENDOR_SUFFIX if
SAMBA_VERSION_VENDOR_SUFFIX is set or "-"SAMBA_VERSION_OFFICIAL_STRING
only if MOUNT_CIFS_VENDOR_SUFFIX is undefined.

This results in: mount.cifs -V
mount.cifs version: 1.10-3.1.2pre1-SVN-build-13706-foovendor
or
mount.cifs version: 1.10-3.1.2pre1-SVN-build-13706

Steve: If this is to long or you do not like it, we might add something
lile -VV to report the added part.
(This used to be commit 3c277c7a3c)
2007-10-10 11:10:50 -05:00
Steve French
03bb57c219 r13697: Remove unneeded header (header not present on all Linux either) for umount.cifs.c
(This used to be commit d294b28f1c)
2007-10-10 11:10:24 -05:00
Tim Potter
79c8591e2d r13612: #define NO_SYSLOG is dead as a doornail.
(This used to be commit 1d23067e68)
2007-10-10 11:10:19 -05:00
Jeremy Allison
eca035db9a r13535: Fix #2353 based on a patch by William Jojo.
Jeremy.
(This used to be commit fe63a6ee06)
2007-10-10 11:10:11 -05:00
Volker Lendecke
7461a457d1 r13486: Two more -- fix bug 3503
(This used to be commit 62b02a6843)
2007-10-10 11:10:05 -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
aa363846d6 r12912: patch from Tony Mountifield <tony@softins.co.uk> for BUG 3327 (fix bad access to gencache.tdb after fork() in smbmount
(This used to be commit 68399ce04c)
2007-10-10 11:06:06 -05:00
Jeremy Allison
c8f28c92a7 r12555: Fix more load_case_table swegfaults. Arggg.
What I'd give for a global constructor...
Jeremy.
(This used to be commit c970d7d0a5)
2007-10-10 11:05:59 -05:00
Jeremy Allison
5a4881bf39 r12522: Try and fix bug #2926 by removing setlocale(LC_ALL, "C")
and replace calls to isupper/islower/toupper/tolower with
ASCII equivalents (mapping into _w variants).
Jeremy.
(This used to be commit c2752347eb)
2007-10-10 11:05:58 -05:00
Jeremy Allison
a168730dda r12045: More warning fixes... Just a few more to go.
Jeremy.
(This used to be commit cd192ed79a)
2007-10-10 11:05:42 -05:00
Günther Deschner
4e5cdfb668 r12015: When smbspool tries to connect to a printer shared on a standalone
Windows XP box, smbspool has to mimic smbclient behaviour and also send
a password-less NTLMSSP session setup.

Guenther
(This used to be commit 1136862e6d)
2007-10-10 11:05:41 -05:00
Jeremy Allison
0732d25057 r11978: Volker's fix for #3292 (smbclient spins if server terminates
connection).
Jeremy.
(This used to be commit 9b8602e055)
2007-10-10 11:05:41 -05:00