Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-6]: src/sys Pull up following revision(s) (requested by nakayama ...
details: https://anonhg.NetBSD.org/src/rev/49dc0836e818
branches: netbsd-6
changeset: 775545:49dc0836e818
user: riz <riz%NetBSD.org@localhost>
date: Thu Nov 29 00:04:37 2012 +0000
description:
Pull up following revision(s) (requested by nakayama in ticket #725):
sys/fs/smbfs/smbfs_smb.c: revision 1.43
sys/netsmb/smb_smb.c: revision 1.33
- fix endian cofusion around FID, which is used as is, so no need
to do byte swapping.
- put right value to ByteCount of SMB_COM_NT_CREATE_ANDX request.
The fix makes smbfs actually works on big-endian port.
diffstat:
sys/fs/smbfs/smbfs_smb.c | 9 ++++-----
sys/netsmb/smb_smb.c | 8 ++++----
2 files changed, 8 insertions(+), 9 deletions(-)
diffs (80 lines):
diff -r efe08cc4e168 -r 49dc0836e818 sys/fs/smbfs/smbfs_smb.c
--- a/sys/fs/smbfs/smbfs_smb.c Thu Nov 29 00:00:02 2012 +0000
+++ b/sys/fs/smbfs/smbfs_smb.c Thu Nov 29 00:04:37 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: smbfs_smb.c,v 1.42 2011/09/27 02:05:10 christos Exp $ */
+/* $NetBSD: smbfs_smb.c,v 1.42.8.1 2012/11/29 00:04:37 riz Exp $ */
/*-
* Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -64,7 +64,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: smbfs_smb.c,v 1.42 2011/09/27 02:05:10 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: smbfs_smb.c,v 1.42.8.1 2012/11/29 00:04:37 riz Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -689,7 +689,7 @@
smb_rq_getreply(rqp, &mdp);
md_get_uint8(mdp, &wc);
if (wc == 1)
- md_get_uint16le(mdp, &fid);
+ md_get_uint16(mdp, &fid);
else
error = EBADRPC;
}
@@ -1422,8 +1422,6 @@
mb_put_uint8(mbp, 0); /* Security tracking mode flags */
smb_rq_wend(rqp);
smb_rq_bstart(rqp);
- smb_rq_bend(rqp);
- mbp->mb_count = 0;
error = smbfs_fullpath(mbp, SSTOVC(ssp), np, NULL, 0);
if (error)
@@ -1435,6 +1433,7 @@
flen = mbp->mb_count;
SMBRQ_PUTLE16(nmlen, flen);
+ smb_rq_bend(rqp);
error = smb_rq_simple(rqp);
if (error)
goto bad;
diff -r efe08cc4e168 -r 49dc0836e818 sys/netsmb/smb_smb.c
--- a/sys/netsmb/smb_smb.c Thu Nov 29 00:00:02 2012 +0000
+++ b/sys/netsmb/smb_smb.c Thu Nov 29 00:04:37 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: smb_smb.c,v 1.32 2009/10/18 23:20:31 tron Exp $ */
+/* $NetBSD: smb_smb.c,v 1.32.18.1 2012/11/29 00:04:37 riz Exp $ */
/*
* Copyright (c) 2000-2001 Boris Popov
@@ -38,7 +38,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: smb_smb.c,v 1.32 2009/10/18 23:20:31 tron Exp $");
+__KERNEL_RCSID(0, "$NetBSD: smb_smb.c,v 1.32.18.1 2012/11/29 00:04:37 riz Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -175,7 +175,7 @@
SMBERROR(("Unexpected length of security blob (%d)\n", sblen));
break;
}
- error = md_get_uint16(mdp, &bc);
+ error = md_get_uint16le(mdp, &bc);
if (error)
break;
if (sp->sv_caps & SMB_CAP_EXT_SECURITY)
@@ -210,7 +210,7 @@
if (swlen > SMB_MAXCHALLENGELEN)
break;
md_get_uint16(mdp, NULL); /* mbz */
- if (md_get_uint16(mdp, &bc) != 0)
+ if (md_get_uint16le(mdp, &bc) != 0)
break;
if (bc < swlen)
break;
Home |
Main Index |
Thread Index |
Old Index