summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1996-05-30 03:16:17 +0000
committerAndrew Tridgell <tridge@samba.org>1996-05-30 03:16:17 +0000
commit1b87ef2440898e73f438f8816c8c3da5af6e7d66 (patch)
tree8d4564871464c047e41b9c99c01fc52b057b53db /source3
parent5e1d10f20fb50e004a75f4a8f77f8634f301f0f8 (diff)
downloadsamba-1b87ef2440898e73f438f8816c8c3da5af6e7d66.tar.gz
samba-1b87ef2440898e73f438f8816c8c3da5af6e7d66.tar.bz2
samba-1b87ef2440898e73f438f8816c8c3da5af6e7d66.zip
- added an entry on WinDD to samba.faq
- added a sample smb.conf from Thoralf.Freitag@remserv.rz.fhtw-berlin.de - print the errno when you get a can't change directory error - added installscripts.sh from James_K._Foote.PARC@xerox.com (This used to be commit 48c6b86d4c580d62ef46132dc04ce2b1d14e21e8)
Diffstat (limited to 'source3')
-rwxr-xr-xsource3/script/installscripts.sh26
-rw-r--r--source3/smbd/server.c5
2 files changed, 29 insertions, 2 deletions
diff --git a/source3/script/installscripts.sh b/source3/script/installscripts.sh
new file mode 100755
index 0000000000..a3defa16e1
--- /dev/null
+++ b/source3/script/installscripts.sh
@@ -0,0 +1,26 @@
+#!/bin/sh
+# this script courtesy of James_K._Foote.PARC@xerox.com
+INSTALLPERMS=$1
+BINDIR=$2
+SRCDIR=$3
+
+echo Installing scripts in $BINDIR
+
+for d in $BINDIR; do
+ if [ ! -d $d ]; then
+ mkdir $d
+ if [ ! -d $d ]; then
+ echo Failed to make directory $d
+ exit 1
+ fi
+ fi
+done
+
+cp $SRCDIR/smbtar $BINDIR
+cp $SRCDIR/addtosmbpass $BINDIR
+echo Setting permissions on scripts
+chmod $INSTALLPERMS $BINDIR/smbtar
+chmod $INSTALLPERMS $BINDIR/addtosmbpass
+
+echo Scripts installed
+exit 0
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index 00f8c9e0fd..5ef92777b2 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -2626,6 +2626,7 @@ int reply_nt1(char *outbuf)
int capabilities=0x300; /* has dual names + lock_and_read */
int secword=0;
BOOL doencrypt = SMBENCRYPT();
+ time_t t = time(NULL);
if (lp_security()>=SEC_USER) secword |= 1;
if (doencrypt) secword |= 2;
@@ -2660,8 +2661,8 @@ int reply_nt1(char *outbuf)
SIVAL(outbuf,smb_vwv3+1,0xFFFF); /* max buffer */
SIVAL(outbuf,smb_vwv5+1,0xFFFF); /* raw size */
SIVAL(outbuf,smb_vwv9+1,capabilities); /* capabilities */
- put_long_date(outbuf+smb_vwv11+1,time(NULL));
- SSVALS(outbuf,smb_vwv15+1,TimeDiff(time(NULL))/60);
+ put_long_date(outbuf+smb_vwv11+1,t);
+ SSVALS(outbuf,smb_vwv15+1,TimeDiff(t)/60);
return (smb_len(outbuf)+4);
}