Unconditionally scan at start
authorTim Pepper <timothy.c.pepper@linux.intel.com>
Fri, 28 Sep 2012 16:53:31 +0000 (09:53 -0700)
committerTim Pepper <timothy.c.pepper@linux.intel.com>
Fri, 28 Sep 2012 16:53:31 +0000 (09:53 -0700)
Originally there was an unconditional scan on start up followed by an
exit if in test mode.  With the changes I started for making things
more event driven, I moved that initial scan to an 'if test mode, scan
then exit' block.  We do actually want to always scan on start to get
existing reports processed promptly.

Signed-off-by: Tim Pepper <timothy.c.pepper@linux.intel.com>
src/corewatcher.c

index 457eb1a..d7b9fa8 100644 (file)
@@ -267,8 +267,9 @@ int main(int argc, char**argv)
        if (!debug)
                sleep(20);
 
+       scan_corefolders(NULL);
+
        if (testmode) {
-               scan_corefolders(NULL);
                fprintf(stderr, "+ Exiting from testmode\n");
                goto out;
        }