The Trunk: Network-ar.50.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Network-ar.50.mcz

commits-2
Andreas Raab uploaded a new version of Network to project The Trunk:
http://source.squeak.org/trunk/Network-ar.50.mcz

==================== Summary ====================

Name: Network-ar.50
Author: ar
Time: 13 January 2010, 10:30:53.169 pm
UUID: 6a3131ca-4e1b-1a45-87bc-8712a12f8d12
Ancestors: Network-ul.49

Fix SocketStream>>peek.

=============== Diff against Network-ul.49 ===============

Item was changed:
  ----- Method: SocketStream>>peek (in category 'stream in') -----
  peek
  "Return next byte, if inBuffer is empty
  we recieve some more data and try again.
  Do not consume the byte."
 
  self atEnd ifTrue: [^nil].
  self isInBufferEmpty ifTrue:
  [self receiveData.
  self atEnd ifTrue: [^nil]].
+ ^inBuffer at: lastRead+1!
- ^inBuffer at: lastRead!


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: Network-ar.50.mcz

Nicolas Cellier
Please don't forget peekFor:

2010/1/14  <[hidden email]>:

> Andreas Raab uploaded a new version of Network to project The Trunk:
> http://source.squeak.org/trunk/Network-ar.50.mcz
>
> ==================== Summary ====================
>
> Name: Network-ar.50
> Author: ar
> Time: 13 January 2010, 10:30:53.169 pm
> UUID: 6a3131ca-4e1b-1a45-87bc-8712a12f8d12
> Ancestors: Network-ul.49
>
> Fix SocketStream>>peek.
>
> =============== Diff against Network-ul.49 ===============
>
> Item was changed:
>  ----- Method: SocketStream>>peek (in category 'stream in') -----
>  peek
>        "Return next byte, if inBuffer is empty
>        we recieve some more data and try again.
>        Do not consume the byte."
>
>        self atEnd ifTrue: [^nil].
>        self isInBufferEmpty ifTrue:
>                [self receiveData.
>                self atEnd ifTrue: [^nil]].
> +       ^inBuffer at: lastRead+1!
> -       ^inBuffer at: lastRead!
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: Network-ar.50.mcz

Igor Stasenko
2010/1/14 Nicolas Cellier <[hidden email]>:
> Please don't forget peekFor:
>
I didn't checked it.

> 2010/1/14  <[hidden email]>:
>> Andreas Raab uploaded a new version of Network to project The Trunk:
>> http://source.squeak.org/trunk/Network-ar.50.mcz
>>
>> ==================== Summary ====================
>>
>> Name: Network-ar.50
>> Author: ar
>> Time: 13 January 2010, 10:30:53.169 pm
>> UUID: 6a3131ca-4e1b-1a45-87bc-8712a12f8d12
>> Ancestors: Network-ul.49
>>
>> Fix SocketStream>>peek.
>>
>> =============== Diff against Network-ul.49 ===============
>>
>> Item was changed:
>>  ----- Method: SocketStream>>peek (in category 'stream in') -----
>>  peek
>>        "Return next byte, if inBuffer is empty
>>        we recieve some more data and try again.
>>        Do not consume the byte."
>>
>>        self atEnd ifTrue: [^nil].
>>        self isInBufferEmpty ifTrue:
>>                [self receiveData.
>>                self atEnd ifTrue: [^nil]].
>> +       ^inBuffer at: lastRead+1!
>> -       ^inBuffer at: lastRead!
>>
>>
>>
>
>



--
Best regards,
Igor Stasenko AKA sig.