summaryrefslogtreecommitdiff
path: root/source3/lib/util.c
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>2000-01-03 19:19:48 +0000
committerLuke Leighton <lkcl@samba.org>2000-01-03 19:19:48 +0000
commitfbd17c8dafeefac788f4bc1c41045726825f513f (patch)
tree93aea0a144e9f649d32d7340e12ec9965aab6825 /source3/lib/util.c
parent632b4f806eae15e319b8f62caef5d25634cf720c (diff)
downloadsamba-fbd17c8dafeefac788f4bc1c41045726825f513f.tar.gz
samba-fbd17c8dafeefac788f4bc1c41045726825f513f.tar.bz2
samba-fbd17c8dafeefac788f4bc1c41045726825f513f.zip
simple mods to add msrpc pipe redirection. default behaviour: fall back
to using internal msrpc code in smbd. (This used to be commit 8976e26d46cb991710bc77463f7f928ac00dd4d8)
Diffstat (limited to 'source3/lib/util.c')
-rw-r--r--source3/lib/util.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/source3/lib/util.c b/source3/lib/util.c
index 0ad14ad3ae..1a893c52ce 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -358,6 +358,21 @@ BOOL file_exist(char *fname,SMB_STRUCT_STAT *sbuf)
}
/*******************************************************************
+ rename a unix file
+********************************************************************/
+int file_rename(char *from, char *to)
+{
+ int rcode = rename (from, to);
+
+ if (errno == EXDEV)
+ {
+ /* Rename across filesystems needed. */
+ rcode = copy_reg (from, to);
+ }
+ return rcode;
+}
+
+/*******************************************************************
check a files mod time
********************************************************************/
time_t file_modtime(char *fname)