config: always ignore silent profile when testing
authorAlex Badea <vamposdecampos@gmail.com>
Mon, 21 Jun 2010 20:42:04 +0000 (23:42 +0300)
committerAlex Badea <vamposdecampos@gmail.com>
Mon, 21 Jun 2010 20:52:37 +0000 (23:52 +0300)
src/config.c

index 8a82c8d..46773be 100644 (file)
@@ -69,7 +69,8 @@ void cfg_speak(struct espeaktime_settings *cfg, gboolean test_mode)
        strftime(text, sizeof(text), cfg->text, tm);
 
        setenv("EST_TESTMODE", test_mode ? "1" : "0", 1);
        strftime(text, sizeof(text), cfg->text, tm);
 
        setenv("EST_TESTMODE", test_mode ? "1" : "0", 1);
-       setenv("EST_IGN_SILENT", cfg->ignore_silent ? "1" : "0", 1);
+       setenv("EST_IGN_SILENT", (cfg->ignore_silent || test_mode)
+               ? "1" : "0", 1);
 
        pid = fork();
        if (pid < 0) {
 
        pid = fork();
        if (pid < 0) {