Re: Patch for Win32 blocking problem

From: Teodor Sigaev <teodor(at)sigaev(dot)ru>
To: Teodor Sigaev <teodor(at)sigaev(dot)ru>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Patch for Win32 blocking problem
Date: 2006-10-12 10:30:30
Message-ID: 452E1946.3070205@sigaev.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Attached patch implements that idea.

> May be that way (untested):
>
> if ( isUDP && (what & FP_WRITE) )
> for(;;) {
> r = WaitForMultipleObjects(100 ms);
> if ( r == WAIT_TIMEOUT ) {
> r == WSASend( sero packet ); /* see comments in pgwin32_select()
> */
> [ analyze result of WSASend:
> * if success then return 1
> * WSAEWOULDBLOCK - continue loop
> * SOCKET_ERROR - return 0
> ]
> } else
> break;
> }

--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/

Attachment Content-Type Size
win32_1.patch.gz application/x-tar 1.4 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Mark Woodward 2006-10-12 10:58:46 Re: Hints WAS: Index Tuning Features
Previous Message Martijn van Oosterhout 2006-10-12 09:57:26 Re: GROUP BY on a large table -- an idea