15 lines
380 B
Ada
15 lines
380 B
Ada
with Ada.Interrupts; use Ada.Interrupts;
|
|
with Ada.Interrupts.Names; use Ada.Interrupts.Names;
|
|
|
|
package Sigint_Handler is
|
|
pragma Unreserve_All_Interrupts;
|
|
|
|
protected Handler is
|
|
entry Wait;
|
|
procedure Handle;
|
|
pragma Attach_Handler (Handle, Ada.Interrupts.Names.SIGINT);
|
|
private
|
|
Call_Count : Natural := 0;
|
|
end Handler;
|
|
end Sigint_Handler;
|