Hi,

I think I've discovered an problem in the following class>>method but still 
considering myself somewhat of a newbie, I'm not entirely sure:

GRPharoPlatform>>isIpAddress: aString
        | ip |
        ip := aString findTokens: '.'.
        ^ ip size = 4
                and: [ ip allSatisfy: [ :each | each greaseInteger notNil
                        and: [ each greaseInteger notNil between: 0 and: 255] ] 
]


The problem is the last line "each greaseInteger notNil between: 0 and: 255"... 
where the notNil message returns a true or false, and it does not respond to 
"between:and:". I believe the fix ought to be to remove the "notNil" in the 
last line to result in the line:
         "each greaseInteger between: 0 and: 255" 
since the "notNil" is already considered before the "and:".


This is from the most recent One-click download:
        Pharo1.3
        Latest update: #13307

------------------------------------------------------
Marco A. Gonzalez




Reply via email to