cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: poll & Mac OS X 10.4

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Fri, 13 May 2005 20:02:08 +0200 (CEST)

On Fri, 13 May 2005, Grigory Entin wrote:

> As far as I understand, older versions of Mac OS X (e.g. 10.3) do have "bad"
> poll behavior, that results in HAVE_FINE_POLL undefined by configure.
> However, under 10.4 the configure test is passed and HAVE_FINE_POLL is
> defined.

Aha. I didn't know that.

There's "porting unix apps to mac os x" page (at
http://developer.apple.com/technotes/tn2002/tn2071.html) however, that still
claims that

  poll
     This API is not supported in Mac OS X, instead, the function select is
     used.

> According to "curl -v <url>", it gets all the page content (up to the
> end), but then waits for "something". When built under 10.3 or even
> under 10.4 with HAVE_FINE_POLL (manually) undefined, it downloads the
> page content and "closes" the connection normally.

I guess this calls for me to adjust the test. Unfortunately, it would have to
be a check for OS and then always disable poll on Mac OS X, since I don't know
exactly what features in poll() that doesn't work in 10.4. Obviously the
waiting-on-nothing check that used to not work isn't good enough to detect a
bad poll().

> The strange thing is that Mac OS X "built-in" curl (7.13.1) works fine.
> According to curl-config it's indistinguishable from the version that I
> build manually, but apparently it is..

Have you tried to strace (or similar, I believe it might be called ktrace) it
to see if it differs from your own build?

I mean, while waiting for a reply from someone who actually knows this. ;-)

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2005-05-13