Changeset 688 for trunk/guitools/shared/smbtree.vrs
- Timestamp:
- Feb 7, 2012, 9:30:41 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/guitools/shared/smbtree.vrs
r660 r688 5 5 say time()' _RefreshTree() started' 6 6 FirstRun = 0 7 7 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", "Refreshing network") 8 8 ok = SysFileDelete(samba.!msg) 9 9 … … 36 36 37 37 stat = stream(samba.!serverlist,'c','open read') 38 if stat <> "READY:" then return 38 if stat <> "READY:" then do 39 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", VRGet("DT_STATUSBAR","Caption")||'.') 40 return 41 end 39 42 40 43 if UserCred = 'USERCRED' | UserCred = '' | UserCred = '--user=%' then UserCred = '-N' … … 392 395 if BroadCast = 1 then BroadCast = '-b'; else BroadCast = '' 393 396 394 say ' 'samba.!smbtreeexe' 'BroadCast' -D 'debuglevel' 'UserCred' >'samba.!msg 395 address cmd samba.!smbtreeexe' 'BroadCast' -D 'debuglevel' 'UserCred' >'samba.!msg 397 call VRSet VRWindow(), 'Pointer', 'Wait' 398 say ' detach 'samba.!smbtreeexe' 'BroadCast' -D 'debuglevel' 'UserCred' >'samba.!msg 399 address cmd 'detach 'samba.!smbtreeexe' 'BroadCast' -D 'debuglevel' 'UserCred' >'samba.!msg 400 401 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption","Enumerating workgroups") 402 do while stream(samba.!msg,'c','open read') <> "READY:" 403 ok = SysSleep(1) 404 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", VRGet("DT_STATUSBAR","Caption")||'.') 405 end 406 call VRSet VRWindow(), 'Pointer', '<default>' 396 407 397 408 if BroadCast = '-b' then BroadCast = 1; else BroadCast = 0 … … 445 456 /* Get all IP addresses of the machine */ 446 457 machine = arg(1) 447 say ' 'samba.!nmblookupexe' 'machine' 'debuglevel' >'samba.!msg 448 address cmd samba.!nmblookupexe' 'machine' 'debuglevel' >'samba.!msg 458 call VRSet VRWindow(), 'Pointer', 'Wait' 459 say ' detach 'samba.!nmblookupexe' 'machine' 'debuglevel' >'samba.!msg 460 address cmd 'detach 'samba.!nmblookupexe' 'machine' 'debuglevel' >'samba.!msg 461 462 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption","Obtaining IP from "machine) 463 do while stream(samba.!msg,'c','open read') <> "READY:" 464 ok = SysSleep(0.33) 465 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", VRGet("DT_STATUSBAR","Caption")||'.') 466 end 467 call VRSet VRWindow(), 'Pointer', '<default>' 468 449 469 ok = file2stem(samba.!msg,"nmblookup.") 450 470 ipstr = ""; ip = "" … … 461 481 _GetMachineMACRoles: procedure expose debuglevel samba. 462 482 machine = arg(1) /* May be name or IP */ 463 say ' 'samba.!nmblookupexe' -A 'machine' 'debuglevel' >'samba.!msg 464 address cmd samba.!nmblookupexe' -A 'machine' 'debuglevel' >'samba.!msg 483 call VRSet VRWindow(), 'Pointer', 'Wait' 484 say ' detach 'samba.!nmblookupexe' -A 'machine' 'debuglevel' >'samba.!msg 485 address cmd 'detach 'samba.!nmblookupexe' -A 'machine' 'debuglevel' >'samba.!msg 486 487 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption","Obtaining capabilities from "machine) 488 do while stream(samba.!msg,'c','open read') <> "READY:" 489 ok = SysSleep(0.33) 490 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", VRGet("DT_STATUSBAR","Caption")||'.') 491 end 492 call VRSet VRWindow(), 'Pointer', '<default>' 465 493 ok = file2stem(samba.!msg,"nmblookup.") 466 494 Roles = "" … … 486 514 _GetMachineNMBStatus: procedure expose debuglevel samba. 487 515 machine = arg(1) /* name only allowed */ 488 say ' 'samba.!nmblookupexe' -S 'machine' 'debuglevel' >'samba.!msg 489 address cmd samba.!nmblookupexe' -S 'machine' 'debuglevel' >'samba.!msg 516 call VRSet VRWindow(), 'Pointer', 'Wait' 517 say ' detach 'samba.!nmblookupexe' -S 'machine' 'debuglevel' >'samba.!msg 518 address cmd 'detach 'samba.!nmblookupexe' -S 'machine' 'debuglevel' >'samba.!msg 519 520 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption","Querying "machine" for roles") 521 do while stream(samba.!msg,'c','open read') <> "READY:" 522 ok = SysSleep(0.33) 523 if VRIsValidObject("DT_STATUSBAR") then ok = VRSet("DT_STATUSBAR","Caption", VRGet("DT_STATUSBAR","Caption")||'.') 524 end 525 call VRSet VRWindow(), 'Pointer', '<default>' 526 490 527 ok = file2stem(samba.!msg,"nmblookup.") 491 528 IPStr = ""
Note:
See TracChangeset
for help on using the changeset viewer.