Ctrl+D doesn't stop application from executing in command window

前端 未结 5 894
后悔当初
后悔当初 2020-12-07 05:21

I\'ve written a program to encrypt a given message by XOR. It works, but It doesn\'t end. Here is the code.(I have created 3 files):

encrypt.h :

void         


        
5条回答
  •  北荒
    北荒 (楼主)
    2020-12-07 05:30

    Just run

      $> kill -l
    

    To see the list of signals in Linux. You will not find SIGKILL (Ctrl + D) signal there :(

    Ctrl + D is SIGKILL (0) signal in Linux which is not documented anywhere. Ctrl + Z is for Windows which tell EOF and we need to press "Enter" to close.

提交回复
热议问题