summaryrefslogtreecommitdiff
path: root/source3/libsmb/libsmbclient.c
diff options
context:
space:
mode:
authorDerrell Lipman <derrell@samba.org>2006-01-29 04:57:42 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:06:18 -0500
commit7ed3868780f72e00687cbd056109ef85ea2ea092 (patch)
treea5daab65939d36dd72a18f53ceb52b9d73779c0f /source3/libsmb/libsmbclient.c
parentc9811b857a7d8407659180a7cc453cead589bb4f (diff)
downloadsamba-7ed3868780f72e00687cbd056109ef85ea2ea092.tar.gz
samba-7ed3868780f72e00687cbd056109ef85ea2ea092.tar.bz2
samba-7ed3868780f72e00687cbd056109ef85ea2ea092.zip
r13216: r12422@cabra: derrell | 2006-01-28 23:57:35 -0500
Fix cli_setpathinfo() to actually do what it's supposed to. Also, get rid of some apparently drug-induced code to deal with create time which isn't being manipulated anyway. (This used to be commit aa25dc1248b15e8e1b39cf8a98496e5aba475c4a)
Diffstat (limited to 'source3/libsmb/libsmbclient.c')
-rw-r--r--source3/libsmb/libsmbclient.c33
1 files changed, 0 insertions, 33 deletions
diff --git a/source3/libsmb/libsmbclient.c b/source3/libsmb/libsmbclient.c
index e992cbbfc4..44cb43c285 100644
--- a/source3/libsmb/libsmbclient.c
+++ b/source3/libsmb/libsmbclient.c
@@ -1523,39 +1523,6 @@ smbc_setatr(SMBCCTX * context, SMBCSRV *srv, char *path,
int ret;
/*
- * Get the create time of the file (if not provided); we'll need it in
- * the set call.
- */
- if (! srv->no_pathinfo && c_time == 0) {
- if (! cli_qpathinfo(&srv->cli, path,
- &c_time, NULL, NULL, NULL, NULL)) {
- /* qpathinfo not available */
- srv->no_pathinfo = True;
- } else {
- /*
- * We got a creation time. Some OS versions don't
- * return a valid create time, though. If we got an
- * invalid time, start with the current time instead.
- */
- if (c_time == 0 || c_time == (time_t) -1) {
- c_time = time(NULL);
- }
-
- /*
- * We got a creation time. For sanity sake, since
- * there is no POSIX function to set the create time
- * of a file, if the existing create time is greater
- * than either of access time or modification time,
- * set create time to the smallest of those. This
- * ensure that the create time of a file is never
- * greater than its last access or modification time.
- */
- if (c_time > a_time) c_time = a_time;
- if (c_time > m_time) c_time = m_time;
- }
- }
-
- /*
* First, try setpathinfo (if qpathinfo succeeded), for it is the
* modern function for "new code" to be using, and it works given a
* filename rather than requiring that the file be opened to have its