]> code.citadel.org Git - citadel.git/blobdiff - citadel/server/room_ops.c
GOTO no longer counts newly arrived mail in the inbox. BIFF now does this.
[citadel.git] / citadel / server / room_ops.c
index cc77735a2628f1f276dbb484082c9b5370b2c515..f9abe87785db6a740bbab734f08083c9859efff3 100644 (file)
@@ -4,11 +4,6 @@
 //
 // This program is open source software; you can redistribute it and/or modify
 // it under the terms of the GNU General Public License, version 3.
-//
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-// GNU General Public License for more details.
 
 #include <stdio.h>
 #include <libcitadel.h>
@@ -38,12 +33,7 @@ int CtdlDoIHavePermissionToReadMessagesInThisRoom(void) {
 // Check to see whether we have permission to post a message in the current
 // room.  Returns a *CITADEL ERROR CODE* and puts a message in errmsgbuf, or
 // returns 0 on success.
-int CtdlDoIHavePermissionToPostInThisRoom(
-       char *errmsgbuf, 
-       size_t n, 
-       PostType PostPublic,
-       int is_reply
-) {
+int CtdlDoIHavePermissionToPostInThisRoom(char *errmsgbuf, size_t n, PostType PostPublic, int is_reply) {
        int ra;
 
        if (!(CC->logged_in) && (PostPublic == POST_LOGGED_IN)) {
@@ -625,9 +615,7 @@ int CtdlIsNonEditable(struct ctdlroom *qrbuf) {
 // Make the specified room the current room for this session.  No validation
 // or access control is done here -- the caller should make sure that the
 // specified room exists and is ok to access.
-void CtdlUserGoto(char *where, int display_result, int transiently,
-               int *retmsgs, int *retnew, long *retoldest, long *retnewest)
-{
+void CtdlUserGoto(char *where, int display_result, int transiently, int *retmsgs, int *retnew, long *retoldest, long *retnewest) {
        int a;
        int new_messages = 0;
        int old_messages = 0;
@@ -637,7 +625,6 @@ void CtdlUserGoto(char *where, int display_result, int transiently,
        int info = 0;
        int rmailflag;
        int raideflag;
-       int newmailcount = 0;
        visit vbuf;
        char truncated_roomname[ROOMNAMELEN];
         struct cdbdata *cdbfr;
@@ -685,9 +672,6 @@ void CtdlUserGoto(char *where, int display_result, int transiently,
        }
        end_critical_section(S_USERS);
 
-       // Check for new mail
-       newmailcount = NewMailCount();
-
        // Set info to 1 if the room banner is new since our last visit.
        // Some clients only want to display it when it changes.
        if (CC->room.msgnum_info > vbuf.v_lastseen) {
@@ -781,7 +765,7 @@ void CtdlUserGoto(char *where, int display_result, int transiently,
                        (long)vbuf.v_lastseen,
                        (int)rmailflag,
                        (int)raideflag,
-                       (int)newmailcount,
+                       0,                                      // new mail is no longer counted here
                        (int)CC->room.QRfloor,
                        (int)vbuf.v_view,
                        (int)CC->room.QRdefaultview,