summaryrefslogtreecommitdiffstats
path: root/source/client/clitar.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix a brown paper bag segfault in clitarVolker Lendecke2008-06-171-1/+1
| | | | | | | Thanks to "No Body is Perfect" from gmail, whoever that is :-) Volker (cherry picked from commit 679d8dfa390601f777bfb43c02cd921eae5edcf4)
* Fix Coverity ID 564Volker Lendecke2008-03-151-10/+0
| | | | finfo1==NULL just does not happen in current code
* Fix Coverity ID 463Volker Lendecke2008-01-241-1/+3
|
* strtok -> strtok_rVolker Lendecke2008-01-231-3/+4
|
* Remove next_token_nr_talloc and its associated globalVolker Lendecke2007-12-211-5/+55
| | | | | | Only client.c and clitar.c used this, I think they should carry the static themselves. Also move the a bit funny routine toktocliplist to clitar.c, the only place where it is used.
* C++ warningVolker Lendecke2007-12-091-1/+1
|
* Remove pstring from clitar.cJeremy Allison2007-12-071-141/+225
| | | | Jeremy
* Add popt to binaries in makefile. Hack clitar to compile until I fix it.Jeremy Allison2007-12-061-12/+7
| | | | Jeremy.
* Fix bug #4393 smbclient does not store files with zero filesize in tar-archivesJeremy Allison2007-11-161-4/+3
| | | | | from tometzky@batory.org.pl. Jeremy.
* More pstring removal. This one was tricky. I had to addJeremy Allison2007-11-151-1/+1
| | | | | | one horror (pstring_clean_name()) which will have to remain until I've removed all pstrings from the client code. Jeremy.
* RIP BOOL. Convert BOOL -> bool. I found a few interestingJeremy Allison2007-10-181-19/+19
| | | | | | | bugs in various places whilst doing this (places that assumed BOOL == int). I also need to fix the Samba4 pidl generation (next checkin). Jeremy.
* r23784: use the GPLv3 boilerplate as recommended by the FSF and the license textAndrew Tridgell2007-10-101-2/+1
|
* r23779: Change from v2 or later to v3 or later.Jeremy Allison2007-10-101-1/+1
| | | | Jeremy.
* r22001: change prototype of dump_data(), so that it takes unsigned char * now,Stefan Metzmacher2007-10-101-1/+1
| | | | | | | | which matches what samba4 has. also fix all the callers to prevent compiler warnings metze
* r21768: Fix the client dfs code such that smbclient canJeremy Allison2007-10-101-1/+1
| | | | | | | | | process deep dfs links (ie. links that go to non root parts of a share). Make the directory handling conanonical in POSIX and Windows pathname processing. dfs should not be fully working in client tools. Please bug me if not. Jeremy.
* r21714: Change the VFS interface to use struct timespecJeremy Allison2007-10-101-1/+1
| | | | | | | | | | for utimes - change the call to ntimes. This preserves nsec timestamps we get from stat (if the system supports it) and only maps back down to usec or sec resolution on time set. Looks bigger than it is as I had to move lots of internal code from using time_t and struct utimebuf to struct timespec. Jeremy.
* r18047: More C++ stuffVolker Lendecke2007-10-101-3/+3
|
* r17850: Another dummy checkin for the build farm to retryVolker Lendecke2007-10-101-1/+1
|
* r17800: Start using struct timespec internally for file timesJeremy Allison2007-10-101-16/+21
| | | | | | | | | 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.
* r16945: Sync trunk -> 3.0 for 3.0.24 code. Still needJeremy Allison2007-10-101-0/+4
| | | | | | | to do the upper layer directories but this is what everyone is waiting for.... Jeremy.
* r16230: Fix Klocwork #861 and others. localtime and asctimeJeremy Allison2007-10-101-1/+1
| | | | | can return NULL. Ensure we check all returns correctly. Jeremy.
* r15141: Fix for #3592 inspired by Justin Best <justinb@pdxmission.org>.Jeremy Allison2007-10-101-19/+30
| | | | | | Ignore a file in a tar output if the first read fails. Also cope with <2GB read fail. Jeremy.
* r14248: Fix Coverity bug # 84Volker Lendecke2007-10-101-0/+1
|
* r14246: Fix Coverity bug # 85Volker Lendecke2007-10-101-0/+2
|
* r14242: Fix Coverity bug # 82Volker Lendecke2007-10-101-0/+2
|
* r14128: Remove warning generated by coverity scan tool (missing SAFE_FREE in ↵Steve French2007-10-101-0/+1
| | | | error path)
* r13915: Fixed a very interesting class of realloc() bugs found by Coverity.Jeremy Allison2007-10-101-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* r13535: Fix #2353 based on a patch by William Jojo.Jeremy Allison2007-10-101-3/+4
| | | | Jeremy.
* r12522: Try and fix bug #2926 by removing setlocale(LC_ALL, "C")Jeremy Allison2007-10-101-1/+1
| | | | | | and replace calls to isupper/islower/toupper/tolower with ASCII equivalents (mapping into _w variants). Jeremy.
* r12045: More warning fixes... Just a few more to go.Jeremy Allison2007-10-101-0/+2
| | | | Jeremy.
* r11511: A classic "friday night check-in" :-). This moves muchJeremy Allison2007-10-101-1/+1
| | | | | | | | | | | | | | | | 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.
* r6225: get rid of warnings from my compiler about nested externsHerb Lewis2007-10-101-1/+1
|
* r5968: derrell's large file fix for libsmbclient (BUG 2505)Gerald Carter2007-10-101-1/+1
|
* r5687: Fix for bug #2398 from Kevin Dalley <kevin@kelphead.org>.Jeremy Allison2007-10-101-5/+1
| | | | | smbtar shouldn't assume /dev/null means dryrun. Jeremy.
* r5295: fix compile issue with MIT 1.4 due to broken gssapi.hGerald Carter2007-10-101-30/+0
|
* r4088: Get medieval on our ass about malloc.... :-). Take control of all our ↵Jeremy Allison2007-10-101-11/+11
| | | | | | | | | allocation functions so we can funnel through some well known functions. Should help greatly with malloc checking. HEAD patch to follow. Jeremy.
* r2835: Since we always have -I. and -I$(srcdir) in CFLAGS, we can get rid ofTim Potter2007-10-101-1/+1
| | | | | '..' from all #include preprocessor commands. This fixes bugzilla #1880 where OpenVMS gets confused about the '.' characters.
* r2361: Fix the appalling toktocliplist() fn. Bug found by Luis Benvenutto.Jeremy Allison2007-10-101-3/+5
| | | | Jeremy.
* r1320: Return an error when the last command read from stdin fails in ↵Jelmer Vernooij2007-10-101-3/+3
| | | | | | smbclient + prepare for better error checking in tar..
* Merge from HEAD for Amanda group.Jeremy Allison2004-03-181-2/+2
| | | | | Apply Craig Barratt's fixes to allow multiple exlusion files and patterns. Jeremy.
* Fix from Craig Barratt <cbarratt@users.sourceforge.net> to fix restoreJeremy Allison2003-09-121-2/+4
| | | | | with filenames > 100 chars. Jeremy.
* Proposed patch for #308. Needs testing.Jeremy Allison2003-09-021-7/+10
| | | | Jeremy
* Print an error instead of crashing if no argument is specified forTim Potter2003-08-271-0/+4
| | | | | | smbclient -T Fixes bug 345.
* Apply a little constVolker Lendecke2003-08-121-1/+1
|
* Reversed replacement. Oops.Jeremy Allison2003-08-061-2/+2
| | | | Jeremy.
* Get rid of MAXPATHLEN, move to standard PATH_MAX.Jeremy Allison2003-08-061-2/+2
| | | | Jeremy.
* Fix the option processing for smbtar. Does no one check this !Jeremy Allison2003-08-011-2/+15
| | | | Jeremy.
* Finish reformatting.Jeremy Allison2003-08-011-516/+467
| | | | Jeremy.
* Reformat lots of clitar code as I hate the style so much :-).Jeremy Allison2003-08-011-563/+540
| | | | Jeremy.
* Reformat clitar option processing - getting ready to fix it for popt...Jeremy Allison2003-08-011-183/+176
| | | | Jeremy.