This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Cygwin hangs up if several keys are typed during outputting a lot of texts.

On Apr 16 11:05, Corinna Vinschen wrote:
> Hi Takashi,
> On Apr 16 09:26, Takashi Yano wrote:
> > So OPOST processing should be in master side for native windows program.
> > However, to solve the second problem I had pointed out in
> > ,
> > OPOST processing should be done on a timing when slave calls write().
> > 
> > To solve this antinomy, I have made a patch attached.
> > 
> > With this patch, new pipe is introduced to handle OPSOT-process separately
> > between native windows program and cygwin program.
> > 
> > Data from cygwin program is passed through the pipe newly introduced.
> > In this case, process_opost_output() is called in fhandler_pty_slave::write().
> > Master reads data, which is already applied OPOST process, from the
> > new pipe.
> > 
> > On the other hands, for native windows program, data is written into
> > conventional pipe. Master forwarding thread, which is also newly
> > introduced, reads conventional pipe and forward the data to the pipe
> > newly introduced by calling process_opost_output(). This makes OPOST
> > processing be done in master side.
> > 
> > I have confirmed that the both problem is fixed with this patch.
> Ok, but... this is a really big patch and it complicates the pty code
> even more.  Is there really no other option as far as the TCSADRAIN
> problem is concerned?
> What strikes me as weird is that neither fhandler_pty_slave::tcsetattr
> nor fhandler_pty_master::tcsetattr give a damn for the optional_actions
> parameter.  They simply overwrite the tc settings.  So I'm wondering,
> wouldn't it be possible to add code to the tcsetattr implementation
> instead, so that TCSADRAIN/TCSAFLUSH are honored and than only have one
> place for OPOST handling?

...and additionally don't have to maintain yet another handle.


Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

Attachment: pgpmEBAg94xUl.pgp
Description: PGP signature

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]