From f2899a64d7a8d232d6c0bf36ee62254a2dd2152d Mon Sep 17 00:00:00 2001 From: Art Cancro Date: Thu, 4 Jun 2009 18:54:28 +0000 Subject: [PATCH] * Eliminated the CtdlCopyMsgsToRoom() function, since it has been reduced to nothing more than a single call to CtdlSaveMsgPointersInRoom(). All uses of this function have been changed to CtdlSaveMsgPointersInRoom() instead. --- citadel/modules/imap/imap_misc.c | 2 +- citadel/modules/newuser/serv_newuser.c | 2 +- citadel/msgbase.c | 15 +-------------- citadel/msgbase.h | 1 - 4 files changed, 3 insertions(+), 17 deletions(-) diff --git a/citadel/modules/imap/imap_misc.c b/citadel/modules/imap/imap_misc.c index 5d40f8503..4f26dd931 100644 --- a/citadel/modules/imap/imap_misc.c +++ b/citadel/modules/imap/imap_misc.c @@ -85,7 +85,7 @@ int imap_do_copy(char *destination_folder) { } if (num_selected > 0) { - CtdlCopyMsgsToRoom(selected_msgs, num_selected, roomname); + CtdlSaveMsgPointersInRoom(roomname, selected_msgs, num_selected, 1, NULL); } free(selected_msgs); diff --git a/citadel/modules/newuser/serv_newuser.c b/citadel/modules/newuser/serv_newuser.c index afcea7e54..eedfee609 100644 --- a/citadel/modules/newuser/serv_newuser.c +++ b/citadel/modules/newuser/serv_newuser.c @@ -87,7 +87,7 @@ void CopyNewUserGreetings(void) { } if (num_msgs > 0) { - CtdlCopyMsgsToRoom(msglist, num_msgs, mailboxname); + CtdlSaveMsgPointersInRoom(mailboxname, msglist, num_msgs, 1, NULL); } /* Now free the memory we used, and go away. */ diff --git a/citadel/msgbase.c b/citadel/msgbase.c index f9c37d96f..9e399fd99 100644 --- a/citadel/msgbase.c +++ b/citadel/msgbase.c @@ -4176,19 +4176,6 @@ void cmd_dele(char *args) } -/* - * Back end API function for moves and deletes (multiple messages) - */ -int CtdlCopyMsgsToRoom(long *msgnums, int num_msgs, char *dest) { - int err; - - err = CtdlSaveMsgPointersInRoom(dest, msgnums, num_msgs, 1, NULL); - if (err != 0) return(err); - - return(0); -} - - /* @@ -4278,7 +4265,7 @@ void cmd_move(char *args) /* * Do the copy */ - err = CtdlCopyMsgsToRoom(msgs, num_msgs, targ); + err = CtdlSaveMsgPointersInRoom(targ, msgs, num_msgs, 1, NULL); if (err != 0) { cprintf("%d Cannot store message(s) in %s: error %d\n", err, targ, err); diff --git a/citadel/msgbase.h b/citadel/msgbase.h index 9786cfd3f..56f248824 100644 --- a/citadel/msgbase.h +++ b/citadel/msgbase.h @@ -162,7 +162,6 @@ int CtdlOutputPreLoadedMsg(struct CtdlMessage *, int crlf, /* 0=LF, 1=CRLF */ int flags /* should the bessage be exported clean? */ ); -int CtdlCopyMsgsToRoom(long *msgnum, int num_msgs, char *dest); int CtdlDoIHavePermissionToDeleteMessagesFromThisRoom(void); enum { -- 2.30.2