delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/01/13/06:03:04

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:date:from:to:subject:message-id:in-reply-to
:references:mime-version:content-type:content-transfer-encoding;
q=dns; s=default; b=nxRB0bq93fuar8QRwBYVmHdBVQIzmnQ/Y4RmrCvS6BE
P3f/JK6Fh7UTOH1S2QN9nqB62G7XIMYRi2MDOPMP8elTN5jtpNsEK3sFUtgeEHyv
qZeevCOJYTgmjioGvsXW6wUfbdCFMDShE5QiPQvTotW9uNYf4QcbS8sQ6Yhb6kZQ
=
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:date:from:to:subject:message-id:in-reply-to
:references:mime-version:content-type:content-transfer-encoding;
s=default; bh=e2n3Lw4y5YQOqWS9gX4stMPtYh4=; b=rtso8PcvvExRcTqs2
RAlvRFioNnxQbzn0ZkquNt5Ebzhwpp1v8B836mhelo/FRv/oFgD6Vkqci1Kc6BGm
d3GpEimah/Uq9uh2szvxTHN4Ijayfp7MIHXT5MtaCl/6ZiuOsSPrin0pap1RsIBL
tkMkDMDQCLsSZg7gU3AxqzJGNM=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
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-Spam-SWARE-Status: No, score=-6.9 required=5.0 tests=AWL,BAYES_00,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.1 spammy=H*f:sk:ad285b6, H*MI:sk:ad285b6, H*i:sk:ad285b6
X-HELO: conssluserg-03.nifty.com
DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-03.nifty.com 00DB1kSR007101
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.ne.jp; s=dec2015msa; t=1578913306; bh=Hi7YrQ+CUOig0rBDUWdqmugGMWfpZBEt47laVO0EOT4=; h=Date:From:To:Subject:In-Reply-To:References:From; b=vEqZBSV+ro/e0pvGFbXhEPnTYyVDdWtjWOZBI2QeHKiyfLa/JOzIH73C23LpuxmZs FAJa2RLzuGTxHsXnDLxO8zItNpmh5KyVK0bH+Dg/G9TsM+5dgeyZEzu5CrhrjdV1qI MlBa9ww5GyVLMe4ugRqLuZx2w9VaxQH8dax2a8YCI93VtWPJwb5LxwjwvPub3oMESE ttfGdo8i608oOrv7DF7nMdJwJPKxlhu4Hs7GPlGqhN8QICZXIPmJZO6zRE0o/bjMFH G9Y8+oOGOHwqpDRB7Zr855l4qi+UBPQXkMJXE7GnBqR9snW1QMX2N3ymdNhpAI1i2J 4nuwFvd9uQmEA==
Date: Mon, 13 Jan 2020 20:01:52 +0900
From: Takashi Yano <takashi DOT yano AT nifty DOT ne DOT jp>
To: cygwin AT cygwin DOT com
Subject: Re: stty -cooked not usable since cygwin-3.1.1-1
Message-Id: <20200113200152.5243a304d481677c61c12450@nifty.ne.jp>
In-Reply-To: <ad285b65-fed9-e6e5-eb3f-432fadc95daf@bahnhof.se>
References: <ad285b65-fed9-e6e5-eb3f-432fadc95daf AT bahnhof DOT se>
Mime-Version: 1.0
X-IsSubscribed: yes

On Mon, 13 Jan 2020 11:52:43 +0100
Rabbe Fogelholm wrote:
> I am running a console Java program that is started from a shellscript
> wrapper. Before invoking Java the wrapper calls `stty -cooked'. The Java
> program polls the keyboard using System.in.available() and reads
> characters immediately using System.in.read(), without waiting for the
> Enter key to be pressed.
> 
> This way of combining `stty -cooked' and Java has stopped working since
> version 3.1.1-1 of the Cygwin package. The Java thread that reads the
> keyboard hangs until Enter is pressed, which is not desirable.
> 
> I had to downgrade to version 3.0.7-1 to resolve the problem.
> 
> Versioning information:
> 
> java version "1.8.0_202"
> Java(TM) SE Runtime Environment (build 1.8.0_202-b08)
> Java HotSpot(TM) 64-Bit Server VM (build 25.202-b08, mixed mode)
> 
> OS Name: Microsoft Windows 10 Pro
> Version: 10.0.17763 Build 17763
> System Type: x64-based PC
> 
> See also the enclosed cygcheck.out.
> 
> To demonstrate the issue I enclose a small Java program that should be
> able to read single keystrokes when `stty -cooked' is in effect.

Does your java program work in command prompt? cygwin 3.1.x uses
pseudo console, so the native (non cygwin) program works as if it
is executed in command prompt.

-- 
Takashi Yano <takashi DOT yano AT nifty DOT ne DOT jp>

--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019