From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 93215 invoked by alias); 13 Jan 2017 00:54:17 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 92909 invoked by uid 89); 13 Jan 2017 00:54:17 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=crazy, Especially, af_unix, AF_UNIX X-HELO: mail-oi0-f50.google.com Received: from mail-oi0-f50.google.com (HELO mail-oi0-f50.google.com) (209.85.218.50) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 13 Jan 2017 00:54:07 +0000 Received: by mail-oi0-f50.google.com with SMTP id w204so43227792oiw.0 for ; Thu, 12 Jan 2017 16:54:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=8psrUgm11/bw1tHtkwRImadm+LR3u8/KERy5NSiyg5E=; b=SzBQvWus0BDXItoZYWUt6544maocPxqKl+YRIugXeUqCJ0YjmV9GiutReigowqnp5x Izv/fOGz3ePqi06NOUNEB/jkvu5RhhXqhPd9DMvxM6ZpL4MFunTLrGo6YyQYM29nk1jL iZ0kI4NJaSZN5QS/z79zJyxOpZEcgNFGP+ytfD/+zpx6xmq8ZoXH2o5qgmt8JeVJNjyf UZFdpeynZ7ue6rAu0pyzQcT1yaJ2nibiy+qXcdg1MqXLneZ6DJSpHvQQEEml1PUchDQP NpHsK/30RRFKG+QZ4TJEeIZf3ZZJgVpFqNHVWyupQ2ID5TwtvRb6CeE4r9iBblA68U3Y 6VKg== X-Gm-Message-State: AIkVDXKO7oOrb3ZUWy+cdpZTdD/Rs0H+NLXPr2ZFxPNcETwyQNQlec5JssQuWVUwU/4KYgteiZ3dUMDc7bTNlQ== X-Received: by 10.202.175.10 with SMTP id y10mr8663686oie.188.1484268845143; Thu, 12 Jan 2017 16:54:05 -0800 (PST) MIME-Version: 1.0 Received: by 10.157.12.166 with HTTP; Thu, 12 Jan 2017 16:54:04 -0800 (PST) In-Reply-To: <20170112221323.GE23119@calimero.vinschen.de> References: <20170109141306.GB843@calimero.vinschen.de> <20170109171635.GB26337@calimero.vinschen.de> <20170112221323.GE23119@calimero.vinschen.de> From: Michael Enright Date: Fri, 13 Jan 2017 00:54:00 -0000 Message-ID: Subject: Re: Hangs on connect to UNIX socket being listened on in the same process (was: Cygwin hanging in pselect) To: cygwin@cygwin.com Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2017-01/txt/msg00134.txt.bz2 On Thu, Jan 12, 2017 at 2:13 PM, Corinna Vinschen wrote: > Step 3: > > If we did it really intelligent, maybe we finally also have a method > to implement descriptor passing. Finally. After all these years. > > And maybe, we should not actually use the socket itself to exchange > the information but rather create some kind of side-channle for that. > > Especially in terms of step 3, I'm mulling over this for years now > and always something else got in the way and had to be done first. > > I made a program that needed to pass windows HANDLEs between processes and so that receiving process could access the shared memory represented by the HANDLEs. I was emulating facilities many programs implement using send_msg, but I was using Windows (named?) pipes. It felt a lot like what you need for send_msg, and it required newer Windows APIs. So by doing the crazy thing of completely rewriting your AF_UNIX sockets you could "easily" add descriptor passing. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple