View previous topic :: View next topic |
Author |
Message |
ranmakun Guru
Joined: 06 Nov 2002 Posts: 372 Location: Buenos Aires - Argentina
|
Posted: Sun Jun 06, 2004 4:43 pm Post subject: Disable ctrl+c in console |
|
|
This is my problem, I have an application that runs un the console (with frame buffer) and I've noticed that if I press ctrl+c it goes out of it, thats very annoying. I need to disable that, I've searched google groups and found that I could do:
To disable the ctrl+c combination of keys, and, if I ping my machine for example it works fine. But it doesn't affect my application and I still can quit with ctrl+c.
The programs I'm using are AdvanceMAME and AdvanceMENU. In X this doesn't happen, but the machine where I'm using this doesn't use X.
Is there a way to do disable this other than the one I've just tried?, do you know why isn't that way working?, Any other ideas?
Thank you. |
|
Back to top |
|
|
edgarguzman n00b
Joined: 07 Jan 2004 Posts: 45 Location: Guatemala
|
Posted: Sun Jun 06, 2004 7:12 pm Post subject: |
|
|
Try with CTRL+Z folowing CTRL+C |
|
Back to top |
|
|
Negated Void l33t
Joined: 25 Dec 2002 Posts: 672
|
Posted: Sun Jun 06, 2004 7:48 pm Post subject: |
|
|
He dosn't want to USE ctrl c, he wants to diable it! |
|
Back to top |
|
|
Anior Guru
Joined: 17 Apr 2003 Posts: 317 Location: European Union (Stockholm / Sweden)
|
Posted: Mon Jun 07, 2004 9:23 am Post subject: |
|
|
ctrl-c is interpreted by bash. A quick and dirty way of disabling it (and all other escape keys) would be to no run bash underneath. Either make advancemenu your default shell (but make sure that you have a seperate user to do other things with) or use exec. Exec forks, then kills the parent, useful for a lot of stuff. Course you will have to login again when your done with mame. |
|
Back to top |
|
|
ranmakun Guru
Joined: 06 Nov 2002 Posts: 372 Location: Buenos Aires - Argentina
|
Posted: Mon Jun 07, 2004 2:33 pm Post subject: |
|
|
Anior wrote: | ctrl-c is interpreted by bash. A quick and dirty way of disabling it (and all other escape keys) would be to no run bash underneath. Either make advancemenu your default shell (but make sure that you have a seperate user to do other things with) or use exec. Exec forks, then kills the parent, useful for a lot of stuff. Course you will have to login again when your done with mame. |
Unfortunatelly, none of the two solutions worked, with ctrl+c it catches the break and returns to the login prompt.
The only solution I found till now is to modify the source to catch the signal and don't do anything. But I'd like to find something that I can use without having to modify the source in every update. |
|
Back to top |
|
|
|