× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Darryl,

Don't use setsockopt() this will not work.

The articles I linked to show you how to use non-blocking sockets together with the select() API to perform timeouts.  There is an example of using this with the connect() API.

The socket() API doesn't have anything to do with connecting, as Brad also said.

-SK

On 2/27/19 4:50 PM, a4g atl wrote:
The problem is

If the device is online,
- I can connect to the device. The socket() is successful.
- If the device is on line but the port is not in listen mode, the program
goes into a wait/retry mode at the connect(). This takes 3.5 minutes before
returning control to the RPG program.

I tried adding the setsock() functions and trying that, but it would not
change the situation.

Darryl.




On Wed, Feb 27, 2019 at 5:21 PM Scott Klement <midrange-l@xxxxxxxxxxxxxxxx>
wrote:

Darryl,

It may be clear in your mind what "the same problem" refers to, but its
not clear in mine. Can you explain what the problem is?

-SK

On 2/27/2019 4:19 PM, a4g atl wrote:
Scott

I tried the methods in your examples (thanks) but I still have the same
problem.

I tried various options from the other suggestions and neither would
work.
I may have made a mistake somewhere but have no way of knowing.

Thanks

Darryl Freinkel.



--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.