]> code.citadel.org Git - citadel.git/commitdiff
* setup.c: system-default message expire policy of "number of
authorArt Cancro <ajc@citadel.org>
Fri, 16 Oct 1998 00:33:31 +0000 (00:33 +0000)
committerArt Cancro <ajc@citadel.org>
Fri, 16 Oct 1998 00:33:31 +0000 (00:33 +0000)
          messages, 150" is now a default configuration instead of a temp hack

citadel/ChangeLog
citadel/setup.c

index 3bd2c2e2ad099d71747474efb68cbb435a0f6a1a..780178e077b62cc3432de0bd4c0b5800f7729bbe 100644 (file)
@@ -2,6 +2,8 @@ Thu Oct 15 19:27:32 EDT 1998 Art Cancro <ajc@uncnsrd.mt-kisco.ny.us>
        * msgbase.c: reimplemented cmd_move()
          room_ops.c: wrote AddMessageToRoom() which is used for both entering
          and moving messages.
+       * setup.c: system-default message expire policy of "number of
+         messages, 150" is now a default configuration instead of a temp hack
 
 Wed Oct 14 22:41:16 EDT 1998 Art Cancro <ajc@uncnsrd.mt-kisco.ny.us>
        * Misc code cleanup
index 6ece366be9b0742a446dfc43e7249d461e24b9de..b925402c16d96550677f860f4126ea8e9619852a 100644 (file)
@@ -825,11 +825,6 @@ void write_config_to_disk(void) {
                display_error("setup: cannot open citadel.config");
                cleanup(1);
                }
-/************************************************************************/
-/* FIX - This is a temporary system-wide default.  Add configurability. */
-       config.c_ep.expire_mode = EXPIRE_NUMMSGS;
-       config.c_ep.expire_value = 150;
-/************************************************************************/
        fwrite((char *)&config,sizeof(struct config),1,fp);
        fclose(fp);
        }
@@ -981,6 +976,14 @@ int main(int argc, char *argv[]) {
                config.c_sleeping = 900;
                }
 
+       /* We need a system default message expiry policy, because this is
+        * the top level and there's no 'higher' policy to fall back on.
+        */
+       if (config.c_ep.expire_mode == 0) {
+               config.c_ep.expire_mode = EXPIRE_NUMMSGS;
+               config.c_ep.expire_value = 150;
+               }
+
        /* Go through a series of dialogs prompting for config info */
        for (curr = 1; curr <= MAXSETUP; ++curr) {
                edit_value(curr);