delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-developers/2000/09/15/09:00:10

Mailing-List: contact cygwin-developers-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-developers-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin-developers/>
List-Post: <mailto:cygwin-developers AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-developers-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-developers-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin-developers AT sources DOT redhat DOT com
Date: Fri, 15 Sep 2000 16:58:22 +0400
From: Egor Duda <deo AT logos-m DOT ru>
X-Mailer: The Bat! (v1.45) Personal
Reply-To: Egor Duda <cygwin-developers AT sourceware DOT cygnus DOT com>
Organization: DEO
X-Priority: 3 (Normal)
Message-ID: <18275375909.20000915165822@logos-m.ru>
To: cygwin-developers AT sourceware DOT cygnus DOT com
Subject: EINTR after SIGSTOP/SIGCONT
Mime-Version: 1.0

Hi!

  this program:

===================================================================
#include <errno.h>
#include <stdio.h>
#include <signal.h>

int main ( int argc, char** argv )
{
  char buf[10];
  int pid;
  int a[2];
  int rc;

  pipe ( a );
  pid = fork ();
  if ( pid == 0 )
    {
      rc = read ( a[0], buf, 1 );
      if ( rc < 0 ) perror ( "error reading from pipe" );
    }
  else  
    {
      kill ( pid, SIGSTOP );
      sleep(1);
      kill ( pid, SIGCONT );
      sleep(1);
      write ( a[1], buf, 1 );
      waitpid ( pid );
    }
}
===================================================================

prints `error reading from pipe: Interrupted system call' on cygwin
and  none  on linux. is it intended behavior, or cygwin shouldn't post
"signal_arrived" event on SIGCONT signal?

Egor.            mailto:deo AT logos-m DOT ru ICQ 5165414 FidoNet 2:5020/496.19


- Raw text -


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