LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-07-2004, 06:25 AM   #1
warney_out
LQ Newbie
 
Registered: Sep 2004
Posts: 10

Rep: Reputation: 0
emulating commands


how to emulate "ctrl+c" from program........
some programs need ctrl+c to exit so i need to give that command from the program code
 
Old 09-07-2004, 08:39 AM   #2
itsme86
Senior Member
 
Registered: Jan 2004
Location: Oregon, USA
Distribution: Slackware
Posts: 1,246

Rep: Reputation: 59
int kill(pid_t pid, int signal);

So: kill(pid, SIGINT); would send to the program what ctrl+c does.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bin/cue emulating mantasman Linux - Software 1 05-27-2005 11:35 PM
emulating a keypress burglus Programming 2 01-29-2005 05:45 AM
Emulating Windows using Qemu greek Linux - Software 3 08-16-2004 11:41 AM
emulating SCO from RH 8.0 Linux jfabiani Linux - Networking 0 04-11-2003 02:42 AM
Emulating buzzbiker Linux - General 4 08-23-2002 01:21 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration