登录
首页 » Linux-Unix program » 用系统调用signal()让父进程捕捉键盘上来的中断信号(按Ctrl

用系统调用signal()让父进程捕捉键盘上来的中断信号(按Ctrl

于 2022-04-29 发布 文件大小:1.24 kB
0 222
下载积分: 2 下载次数: 1

代码说明:

用系统调用signal()让父进程捕捉键盘上来的中断信号(按Ctrl-C键);当捕捉到中断信号后,父进程用系统调用kill()向两个子进程发出信号,子进程捕捉到信号后分别输出下列信息后终止:  Child Process 1 is Killed by Parent!  Child Process 2 is Killed by Parent! 父进程等待两个子进程终止后,输出如下的信息后终止: Parent Process is Killed!-with system call signal () so that the process of capturing the father onto the keyboard interrupt signal (Ctrl-C bond); When the interrupt signal capture, the father of the process of using system calls kill () to process two signals son, the child process to capture the signal output respectively after the termination of the following information : Process is a Child Killed by Parent! Process 2 Child is Killed by Parent! the process of waiting for the father of two-after the termination process, the following information output after termination : Parent Process is Killed!

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • 周立功
    ZLG-GUI源代码完整版12-ConvertColor.c-ZLG-GUI source code full version of 22-ConvertColor.c
    2022-03-04 11:00:54下载
    积分:1
  • About: Paco (pacKAGE oRGANIZER) is a simple, yet powerful tool to aid package...
    About: Paco (pacKAGE oRGANIZER) is a simple, yet powerful tool to aid package management when installing programs from source code. It uses the LD_PRELOAD method to track package installations, and provides various options to keep the installed software organized. It s mainly a command line application but it has also an optional GTKMM interface. Release focus: Minor bugfixes Changes: Libpaco-log has been rewritten in C. This prevents a glibc installation failure when building LFS in chapter 6. The option -x|--expand has been removed. Several bugs have been fixed in paco, gpaco, and rpm2paco. Author: David Rosal-About: Paco (pacKAGE oRGANIZER) is a simple, yet powerful tool to aid package management when installing programs from source code. It uses the LD_PRELOAD method to track package installations, and provides various options to keep the installed software organized. It s mainly a command line application but it has also an optional GTKMM interface. Rel
    2022-01-31 22:36:41下载
    积分:1
  • Linux设备驱动程序第三版2.6.chm,最新的开发嵌入式参看手册
    Linux设备驱动程序第三版2.6.chm,最新的开发嵌入式参看手册-Linux device drivers third edition 2.6.chm, see the latest Embedded Development Manual
    2023-06-10 18:10:03下载
    积分:1
  • linux下的flash player的一个具体实现,未经验证
    linux下的flash player的一个具体实现,未经验证-linux media player
    2022-01-30 10:47:51下载
    积分:1
  • TcL 中嵌入C代码
    TcL 中嵌入C代码-TcL embedded C code
    2023-04-21 15:00:03下载
    积分:1
  • Linux编程开发相关bash外壳
    bash for linux progrmming to develop shell related
    2023-02-16 01:00:05下载
    积分:1
  • linux 2.6内核版本的设备驱动详解书籍,对linux设备驱动的编写很有用!...
    linux 2.6内核版本的设备驱动详解书籍,对linux设备驱动的编写很有用!-linux 2.6 kernel version of the device driver Xiangjie books, linux device driver for the preparation of very useful!
    2022-01-26 07:54:46下载
    积分:1
  • 通过变量参数列表等功能对GCC
    Passing variable argument list to other functions on G-Passing variable argument list to other functions on GCC
    2022-10-17 06:00:02下载
    积分:1
  • edtftpj
    edtftpj-1.4.5.zip
    2023-05-27 22:10:03下载
    积分:1
  • Linux0.11内核注释
    Linux0.11内核注释-Notes Linux0.11 kernel
    2023-01-06 00:45:04下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载