summaryrefslogtreecommitdiffstats
path: root/source/libsmb
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2000-02-25 22:25:25 +0000
committerJeremy Allison <jra@samba.org>2000-02-25 22:25:25 +0000
commit9f6ad046761adecafba59040baa3abc9f0959e65 (patch)
tree8601bf8f3668d50dab113b252dd27538caeef6b3 /source/libsmb
parentb59233b3b61b17e85f5d5b44cc6f2ced9d27b497 (diff)
downloadsamba-9f6ad046761adecafba59040baa3abc9f0959e65.tar.gz
samba-9f6ad046761adecafba59040baa3abc9f0959e65.tar.xz
samba-9f6ad046761adecafba59040baa3abc9f0959e65.zip
client/client.c:
libsmb/clientgen.c: Fixes for Win2k smbclient browsing. Other fixes implement smbpasswd -x user to delete users. Also allows swat to do the same. Jeremy.
Diffstat (limited to 'source/libsmb')
-rw-r--r--source/libsmb/clientgen.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/source/libsmb/clientgen.c b/source/libsmb/clientgen.c
index df3df0b4ba3..8d7dbec8590 100644
--- a/source/libsmb/clientgen.c
+++ b/source/libsmb/clientgen.c
@@ -600,7 +600,7 @@ BOOL cli_NetWkstaUserLogon(struct cli_state *cli,char *user, char *workstation)
/****************************************************************************
call a NetShareEnum - try and browse available connections on a host
****************************************************************************/
-BOOL cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, const char *))
+int cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, const char *))
{
char *rparam = NULL;
char *rdata = NULL;
@@ -618,12 +618,16 @@ BOOL cli_RNetShareEnum(struct cli_state *cli, void (*fn)(const char *, uint32, c
pstrcpy(p,"B13BWz");
p = skip_string(p,1);
SSVAL(p,0,1);
- SSVAL(p,2,0xFFFF);
+ /*
+ * Win2k needs a *smaller* buffer than 0xFFFF here -
+ * it returns "out of server memory" with 0xFFFF !!! JRA.
+ */
+ SSVAL(p,2,0xFFE0);
p += 4;
if (cli_api(cli,
param, PTR_DIFF(p,param), 1024, /* Param, length, maxlen */
- NULL, 0, 0xFFFF, /* data, length, maxlen */
+ NULL, 0, 0xFFE0, /* data, length, maxlen - Win2k needs a small buffer here too ! */
&rparam, &rprcnt, /* return params, length */
&rdata, &rdrcnt)) /* return data, length */
{