[REBOL] Re: Encryption
From: mattsmac:ho:tmail at: 8-Sep-2003 12:03
Ok, good enough. So if I'm understanding correctly. I should be able to
have 2 binary ports. One sending and one receiving. Then send the data
through the sending port (as binary) and recieve it on the recieving port.
Then change it to string and parse it from there. Here is what is happening
though:
I send a simple message "Hi"
i have to do 2 reads on the recieving port, which returns 72 and 105 - both
integers. So my question is then, why do I get integers instead of binary
data, and if I need to deal with integers and somehow convert them to
characters, how do I know when to stop reading from the recieving port?
Please help this is reallllly frustrating,
Matt
Hi Matt,
MM> Ok, maybe my inexperience is showing or I'm just dense. I need to use
the
MM> line refinement so that I can get the entire line of the message at
once.
MM> But you cannot use the binary and line refinements at the same time.
How do
MM> I get around this?
If you're sending binary data, there is no concept of "lines". You'll
have to send the data and decode it on the other end, breaking it up
in to lines there if necessary.
-- Gregg