Not yet working stack checking (symbol STACKCHECK)
[gnokii.git] / common / devices / device.c
index eb81b25..db6d768 100644 (file)
@@ -157,18 +157,21 @@ static void device_dumpserial(void)
 }
 #endif /* DEBUG */
 
+static char SigHandler_buffer[255];
+
 static void SigHandler(int status)
 {
-
-  unsigned char buffer[2048];
-
   int count, res;
 
-  res = device_read(buffer, 255);
+  LIVE_DISABLE;
+  LIVE;
+
+  res = device_read(SigHandler_buffer, sizeof(SigHandler_buffer));
 
   for (count = 0; count < res ; count ++) {
-    Protocol->StateMachine(buffer[count]);
+    Protocol->StateMachine(SigHandler_buffer[count]);
   }
+  LIVE_ENABLE;
 }