[scripts] flog - Support log skipping upon reboot

This makes "--begin" option still applies upon DUT reboot.

Change-Id: Idbe6c2ef91da1d13de156b910f753a59b0b3d852
diff --git a/flog b/flog
index 52981b9..c3c9d02 100755
--- a/flog
+++ b/flog
@@ -43,6 +43,8 @@
     'CYAN': '\033[1:36m',
 }
 
+FIRST_LOG_AFTER_BOOTUP = '[00000.000] 00000.00000> bootdata:'
+
 
 def static_vars(**kwargs):
 
@@ -97,6 +99,10 @@
   Returns:
     True if the log line should be suppressed. False otherwise.
   """
+  if line.startswith(FIRST_LOG_AFTER_BOOTUP):
+    # A reboot occurs. Reset to default.
+    is_suppressed.is_in_session = False
+
   if not BEGINS or any(keyword in line for keyword in BEGINS):
     if not is_suppressed.is_in_session:
       print '\n' * 3