void
net·runtime_pollOpen(uintptr fd, PollDesc* pd, intgo errno)
{
	pd = 0;
	FLUSH(&pd);
	errno = 0;
	FLUSH(&errno);
#line 96 "C:\Users\gopher\AppData\Local\Temp\1\makerelease745458658\go\src\pkg\runtime\netpoll.goc"

	pd = allocPollDesc();
	runtime·lock(pd);
	if(pd->wg != nil && pd->wg != READY)
		runtime·throw("runtime_pollOpen: blocked write on free descriptor");
	if(pd->rg != nil && pd->rg != READY)
		runtime·throw("runtime_pollOpen: blocked read on free descriptor");
	pd->fd = fd;
	pd->closing = false;
	pd->seq++;
	pd->rg = nil;
	pd->rd = 0;
	pd->wg = nil;
	pd->wd = 0;
	runtime·unlock(pd);

	errno = runtime·netpollopen(fd, pd);
	FLUSH(&pd);
	FLUSH(&errno);
}
Ejemplo n.º 2
0
void
net·runtime_pollOpen(uintptr fd, PollDesc* pd, intgo errno)
{
    pd = 0;
    FLUSH(&pd);
    errno = 0;
    FLUSH(&errno);
#line 96 "/home/14/ren/source/golang/go/src/pkg/runtime/netpoll.goc"

    pd = allocPollDesc();
    runtime·lock(pd);
    if(pd->wg != nil && pd->wg != READY)
        runtime·throw("runtime_pollOpen: blocked write on free descriptor");
    if(pd->rg != nil && pd->rg != READY)
        runtime·throw("runtime_pollOpen: blocked read on free descriptor");
    pd->fd = fd;
    pd->closing = false;
    pd->seq++;
    pd->rg = nil;
    pd->rd = 0;
    pd->wg = nil;
    pd->wd = 0;
    runtime·unlock(pd);

    errno = runtime·netpollopen(fd, pd);
    FLUSH(&pd);
    FLUSH(&errno);
}
Ejemplo n.º 3
0
void
net·runtime_pollOpen(uintptr fd, PollDesc* pd, intgo errno)
{
#line 66 "/tmp/makerelease886106415/go/src/pkg/runtime/netpoll.goc"

	pd = allocPollDesc();
	runtime·lock(pd);
	if(pd->wg != nil && pd->wg != READY)
		runtime·throw("runtime_pollOpen: blocked write on free descriptor");
	if(pd->rg != nil && pd->rg != READY)
		runtime·throw("runtime_pollOpen: blocked read on free descriptor");
	pd->fd = fd;
	pd->closing = false;
	pd->seq++;
	pd->rg = nil;
	pd->rd = 0;
	pd->wg = nil;
	pd->wd = 0;
	runtime·unlock(pd);

	errno = runtime·netpollopen(fd, pd);
	FLUSH(&pd);
	FLUSH(&errno);
}