X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; q=dns; s=default; b=PoMRLTc2/8eYF9es FJozvEfhzIy09aXw+qgUV5Zlta9sAxmq5m3cuWrXKn0Nf1hBpXnObRYJBGQjBykX exy9nDHXgxo59FQheDePonbCtTmAY4vA+tKQOFCt6sq/BysTWh9ItZPbjFpCKgJF zGwxblMQ09UhlwQrJdaE1Wgfvq4= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; s=default; bh=Ej2enrJlWbXWjc1kUc5ehL xEjdw=; b=QdqezzR3khK4TDi+a8xKfrsPtifnXIp2JrMOyeBG7dJko5YaB4X5iJ CUe1UcJh1xuQkgINsJrcfTvoOmVyiu0owFXGpnsecSj0eAu7scGgf/oQR8yBUa9r w0LzTXkb7Pq/fvavyXAFHapV/lU3eOqZR71sCE5JcFspdwArEtGn0= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.4 required=5.0 tests=AWL,BAYES_50,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 spammy=connections, world, Connection, Accept X-HELO: m0.truegem.net Subject: Re: Unable to Accept TCP Connection To: cygwin AT cygwin DOT com References: From: Mark Geisert Message-ID: <6ed83f54-401c-6f2f-83bf-9998323519d3@maxrnd.com> Date: Sat, 21 Apr 2018 16:20:12 -0700 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0 SeaMonkey/2.46 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit R0b0t1 wrote: > The following never prints "Hello, world!" > > > struct sboot_state { > struct sockaddr_in haddr; > struct sockaddr caddr; > socklen_t clen; > int sfd, cfd; > } state = { 0 }; > > state.haddr.sin_family = AF_INET; > state.haddr.sin_port = 2200; You can use the Windows 'netstat' to see listening connections. See if your app shows up on port 2200. But I suspect you need an htons(2200) on the assignment to sin_port. ..mark -- 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