$Log$
+ Revision 590.57 2002/01/11 15:46:57 error
+ * Allow users to move/copy messages between personal rooms
+
Revision 590.56 2002/01/11 04:59:00 ajc
* Finished most of the work for the Global Address Book.
Fri Jul 10 1998 Art Cancro <ajc@uncensored.citadel.org>
* Initial CVS import
+
if ((!is_room_aide)
&& ((room_flags & QR_MAILBOX) ==
0)) {
- if ((e == 'd') || (e == 'm')
- || (e == 'c'))
+ if ((e == 'd') || (e == 'm'))
e = 0;
}
/* print only if available */
printf(" D Delete this message\n");
printf
(" M Move message to another room\n");
- printf
- (" C Copy message to another room\n");
}
+ printf(" C Copy message to another room\n");
if (strlen(printcmd) > 0)
printf(" P Print this message\n");
printf
targ[ROOMNAMELEN - 1] = 0;
is_copy = extract_int(args, 2);
+ if (getroom(&qtemp, targ) != 0) {
+ cprintf("%d '%s' does not exist.\n", ERROR, targ);
+ return;
+ }
+
getuser(&CC->usersupp, CC->curr_user);
+ /* Aides can move/copy */
if ((CC->usersupp.axlevel < 6)
- && (CC->usersupp.usernum != CC->quickroom.QRroomaide)) {
+ /* Roomaides can move/copy */
+ && (CC->usersupp.usernum != CC->quickroom.QRroomaide)
+ /* Permit move/copy to/from personal rooms */
+ && (!((CC->quickroom.QRflags & QR_MAILBOX)
+ && (qtemp.QRflags & QR_MAILBOX)))
+ /* Permit only copy from public to personal room */
+ && (!(is_copy && !(CC->quickroom.QRflags & QR_MAILBOX)
+ && (qtemp.QRflags & QR_MAILBOX)))) {
cprintf("%d Higher access required.\n",
ERROR + HIGHER_ACCESS_REQUIRED);
return;
}
- if (getroom(&qtemp, targ) != 0) {
- cprintf("%d '%s' does not exist.\n", ERROR, targ);
- return;
- }
-
err = CtdlCopyMsgToRoom(num, targ);
if (err != 0) {
cprintf("%d Cannot store message in %s: error %d\n",