Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Telnet protocol scheme weirdness.

 [1/4] from: bga::bug-br::org::br at: 3-Feb-2004 12:07


Hello. I am using the Telnet protocol scheme to control a telnet session with a Rebol script. I am having one small problem that I didn't figured out how to fix: telnet: open telnet://xxx [...] insert telnet #{1B4F42} The end result is that the above line will send #{1B4F420D0A} to the server instead of what I wanted it to (#{1B4F42}). I already tried to change the open line to: telnet: open/binary telnet://xxx But it didn't work. In the Telnet scheme itself, it sets some flags. I wonder if these flags are right: port/state/flags: port/state/flags or system/standard/port-flags/direct or 32 or 2051; No-Wait, BINARY (51) (2048) port/sub-port/state/flags: port/sub-port/state/flags or 2051 or 32 Thanks in advance for any pointers. -Bruno

 [2/4] from: g:santilli:tiscalinet:it at: 3-Feb-2004 15:06


Hi Bruno, On Tuesday, February 3, 2004, 3:07:30 PM, you wrote: BGA> The end result is that the above line will send #{1B4F420D0A} to the BGA> server instead of what I wanted it to (#{1B4F42}). I already tried to BGA> change the open line to: I guess it is opening the sub-port in /LINES mode. BGA> port/state/flags: port/state/flags or BGA> system/standard/port-flags/direct BGA> or 32 or 2051; No-Wait, BINARY (51) (2048) BGA> port/sub-port/state/flags: port/sub-port/state/flags or 2051 or 32 BTW, should use SET-MODES here actually, AFAIK changing the flags directly is deprecated. Regards, Gabriele. -- Gabriele Santilli <[g--santilli--tiscalinet--it]> -- REBOL Programmer Amiga Group Italia sez. L'Aquila --- SOON: http://www.rebol.it/

 [3/4] from: bga:bug-br at: 3-Feb-2004 18:55


On Tue, 3 Feb 2004 15:06:23 +0100, Gabriele Santilli < [g--santilli--tiscalinet--it]> said:
> BGA> The end result is that the above line will send #{1B4F420D0A} to > the > BGA> server instead of what I wanted it to (#{1B4F42}). I already > tried to > BGA> change the open line to: > > I guess it is opening the sub-port in /LINES mode.
Maybe, but I am not finding where it is actually opening it in the scheme code. I did try get-modes on the port and sub-port to determine its flags and both had "binary" and "direct" set to true.
> BGA> port/state/flags: port/state/flags or > BGA> system/standard/port-flags/direct
<<quoted lines omitted: 3>>
> BTW, should use SET-MODES here actually, AFAIK changing the flags > directly is deprecated.
Will change that but I don't think it will help with my problem. Thanks! -Bruno -- Fortune Cookie Says: We may not return the affection of those who like us, but we always respect their good judgement.<

 [4/4] from: g:santilli:tiscalinet:it at: 4-Feb-2004 10:38


Hi Bruno, On Tuesday, February 3, 2004, 8:55:13 PM, you wrote: BGA> Maybe, but I am not finding where it is actually opening it in the BGA> scheme code. I did try get-modes on the port and sub-port to determine BGA> its flags and both had "binary" and "direct" set to true. Did you try: get-modes sub-port get-modes sub-port 'port-modes Anyway, if there's not an explicit OPEN in the scheme code, it's surely using the default in ROOT-PROTOCOL. And that does OPEN/LINES. BGA> Will change that but I don't think it will help with my problem. Maybe not, but makes it more future proof and more readable too. :-) And, you could just try: set-modes sub-port [lines: no] there then. Regards, Gabriele. -- Gabriele Santilli <[g--santilli--tiscalinet--it]> -- REBOL Programmer Amiga Group Italia sez. L'Aquila --- SOON: http://www.rebol.it/

Notes
  • Quoted lines have been omitted from some messages.
    View the message alone to see the lines that have been omitted