Bug 1732 - Win9x client cannot browse share if strlen("sharename in unix charset")>12
Win9x client cannot browse share if strlen("sharename in unix charset")>12
Status: CLOSED FIXED
Product: Samba 3.0
Classification: Unclassified
Component: Extended Characters
3.0.8
All All
: P3 critical
: none
Assigned To: Jim McDonough
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2004-09-07 22:22 UTC by SATOH Fumiyasu
Modified: 2005-08-24 10:25 UTC (History)
1 user (show)

See Also:


Attachments
proposed patch (1.47 KB, patch)
2004-09-07 22:25 UTC, SATOH Fumiyasu
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description SATOH Fumiyasu 2004-09-07 22:22:12 UTC
As far as you and I know, Windows 9x/Me client has a limitation
that sharename is NOT displayed in the browse list if 
strlen("sharename") > 12.

Samba server limits Windows 9x/Me clients to it at smbd/lanman.c as:
 for (i=0;i<count;i++)
   if( lp_browseable( i )
       && lp_snum_ok( i )
       && (strlen( lp_servicename( i ) ) < 13) )   /* Maximum name length. */
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
This statement determines whether to limit or not by
strlen("sharename in unix charset"), i.e. byte width of 
sharename in unix charset. This statement must be
strlen("sharename in dos charset") because Windows 9x/Me's
limitation is based in dos charset, not unix charset.
Comment 1 SATOH Fumiyasu 2004-09-07 22:25:56 UTC
Created attachment 644 [details]
proposed patch

Please apply this patch to SAMBA_3_0 tree.
Comment 2 SATOH Fumiyasu 2004-09-27 01:41:14 UTC
Please comfirm and apply my proposed patch.
Comment 3 Alexander Bokovoy 2004-09-27 01:44:01 UTC
Jim, could you please proceed with this patch to get it in?
Comment 4 Jim McDonough 2004-09-27 10:10:46 UTC
Checked in patch.  Please verify, as I can only check the existing function
didn't break.
Comment 5 Gerald (Jerry) Carter 2005-02-07 09:18:58 UTC
originally reported against 3.0.8pre1.  Cleaning up 
non-production versions.
Comment 6 Gerald (Jerry) Carter 2005-08-24 10:25:37 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.