#54 install-port and negative return values

run-time (53)

>>>>> "Brian" == briand <briand@zipcon.net> writes:

Brian> I've seen this error a couple of times, and it
seems to be randomly
Brian> occuring. Anybody have any ideas ?

Brian> The only thing I can think of is that I keep
opening ports without
Brian> closing them.

Brian> Error: -1
>> "Unknown error 4294967295"
>> #{Procedure 10237 %install-port}
>> 256
>> #{Extensible-input-port}
>> 0

Uhhh... Here is what's going on: %install-port calls
the C procedure
install_port in fdports1.c. The return value of this
procedure is 0 on
success, negative if a scsh internal error occurs and
positive if any
procedure of the C standard library fails.
Unfortunately, the
corresponding Scheme code doesn't take care of the
negative numbers
but coerces everything into a errno. 4294967295 is
0xffffffff or
-1. Install_port returns -1 if the given file
descriptor is either <0
or >= the number of allowed fdports (currently 256). As
the third
argument of the error message you provided is 256, I
suspect, that the
latter case happend.

I have no fix for the broken error message, but I
*guess*, you can
increase the number of fdports by setting NUM_FDPORTS
to a bigger
value in scsh/fdports1.c and run make.

This applies to 0.5.x only!!!


  • Martin Gasbichler

    Logged In: YES

    Deleted since it's only 0.5.X.

  • Martin Gasbichler

    • status: open --> closed-wont-fix

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks