public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Grant Edwards <grante@visi.com>
To: ecos-discuss@ecos.sourceware.org
Subject: [ECOS] Re: bsd sockets question
Date: Thu, 27 Oct 2005 18:49:00 -0000	[thread overview]
Message-ID: <20051027185115.CF1B73C372@rivatek.dnsalias.net> (raw)
In-Reply-To: <43610D3D.2050303@carallon.com>

In gmane.os.ecos.general, you wrote:

> My application has two threads. One thread is waiting on
> receiving data on a socket using the select function, with a
> timeout of forever.
>
> The other thread calls close on that socket.
>
> I was hoping that upon calling close the select function would
> return with an error. Instead it continues to block. This
> thread works on linux and windows so I was hoping it was
> standard BSD sockets functionality.
>
> Should this be working or does eCos not support this? If it
> doesn't support it does anyone have any ideas how to implement
> it, or even where to start?

One possible work-around is to call select_with_abort() instead
of select().  Then when you want to shutdown, call close() and
then cyg_select_abort().

-- 
Grant Edwards                   grante             Yow!  Is this ANYWHERE,
                                  at               USA?
                               visi.com            

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

  reply	other threads:[~2005-10-27 18:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-27 17:23 [ECOS] " Will Wagner
2005-10-27 18:49 ` Grant Edwards [this message]
2005-10-28 15:08 ` Matt Jerdonek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051027185115.CF1B73C372@rivatek.dnsalias.net \
    --to=grante@visi.com \
    --cc=ecos-discuss@ecos.sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).