COMPILATION LISTING OF SEGMENT xmail_file_msgs_ Compiled by: Multics PL/I Compiler, Release 30, of February 16, 1988 Compiled at: Honeywell Bull, Phoenix AZ, SysM Compiled on: 09/02/88 0748.7 mst Fri Options: optimize map 1 /****^ *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Information Systems Inc., 1982 * 4* * * 5* * Copyright (c) 1972 by Massachusetts Institute of * 6* * Technology and Honeywell Information Systems, Inc. * 7* * * 8* *********************************************************** */ 9 10 11 12 /****^ HISTORY COMMENTS: 13* 1) change(86-01-07,Blair), approve(86-02-26,MCR7358), 14* audit(86-05-19,RBarstad), install(86-05-28,MR12.0-1062): 15* Added a new entrypoint to handle the case when both the original 16* and the reply are to be filed. 17* 2) change(86-01-17,Blair), approve(86-02-26,MCR7358), 18* audit(86-05-19,RBarstad), install(86-05-28,MR12.0-1062): 19* Call xmail_error_ with disposition "c" instead of "i" when the user types 20* "no" to creating a new file. TR 20028. 21* 3) change(87-01-19,Blair), approve(87-02-05,MCR7618), 22* audit(87-04-10,RBarstad), install(87-04-26,MR12.1-1025): 23* Check to see whether or not we're dealing with all the messages in a 24* mailbox or only the ordinary ones as indicatd by xmail_data.msgs_as_mail. 25* END HISTORY COMMENTS */ 26 27 28 xmail_file_msgs_: proc (); 29 30 31 /* BEGIN DESCRIPTION 32* 33*history: Author unknown. 34* 35* 83-07-05 DJ Schimke: Modified to use new mail_system calls and version 2 36* mailboxes. 37* 38* 83-10-06 DJ Schimke: Changed call to xmail_get_str_ to call to new entry 39* xmail_get_str_$yes_no. Reorganized the code into two separate entrypoints: 40* 1) current_msgs to provide the old function of filing all messages in 41* the current_msgs structure. 42* 2) single_msg to provide a new message filing function for xmail_reply, 43* xmail_send_msg etc. 44* 45* 83-11-01 DJ Schimke: Changed the calling sequence of xmail_select_file_. 46* 47* 84-08-21 JG Backs: Modified the error code handling of mail_system_$save_ 48* message call within file_message internal procedure to report a better 49* message if there was incorrect access to a save mailbox. phx18059. 50* 51* 84-10-24 JG Backs: Modified the error code handling of mail_system_$save_ 52* message call within file_message internal procedure to report a better 53* message if the file becomes full during filing. This also required that 54* the entrypoint $single_msg always set the message_num to 1, so if the file 55* is full on the 1st message, internal proc print_filed_msg is not called. 56* 57* 84-10-29 JG Backs: Added three new internal procedures, save_message_count, 58* backout_filed_msgs, and close_file, to better handle the "mailbox_full" 59* situation. If a file becomes full during the filing of more than one 60* message, the user is informed and the messages already filed are backed out. 61* 62* 84-11-26 JG Backs: Modified the save_message_count internal procedure to 63* test smc_code for error_table_$noentry rather than mlsys_et_$no_savebox 64* after calling mail_system_$get_message_counts. This is the code that is 65* returned when a file does not exist and is being created. 66* 67* 68*END DESCRIPTION 69**/ 70 71 /* PARAMETERS */ 72 73 dcl P_curr_msgsp ptr parm; /* ptr to current msgs structure */ 74 dcl P_default_file char (32) var parm;/* default target file */ 75 dcl P_mailbox_ptr ptr parm; /* ptr to source mailbox */ 76 dcl P_msg_ptr ptr parm; /* ptr to msg to be filed */ 77 dcl P_orig_msg_ptr ptr parm; /* ptr to original msg to file */ 78 dcl P_reply_msg_ptr ptr parm; /* ptr to the reply msg */ 79 dcl P_allow_selection bit (1) aligned parm; 80 /* do we use the default file or */ 81 /* can we select another? */ 82 83 84 /* ENTRIES */ 85 86 dcl continue_to_signal_ entry (fixed bin (35)); 87 dcl ioa_ entry () options (variable); 88 dcl ioa_$rsnnl entry () options (variable); 89 dcl mail_system_$close_mailbox entry (ptr, ptr, fixed bin (35)); 90 dcl mail_system_$get_message_counts entry (char (*), char (*), bit (1) aligned, fixed bin, fixed bin, fixed bin, fixed bin (35)); 91 dcl mail_system_$mark_message_for_deletion entry (ptr, fixed bin (35)); 92 dcl mail_system_$open_mailbox entry (char (*), char (*), ptr, char (8), ptr, fixed bin (35)); 93 dcl mail_system_$read_message entry (ptr, fixed bin, fixed bin (35)); 94 dcl mail_system_$save_message entry (ptr, char (*), char (*), bit (1) aligned, fixed bin (35)); 95 dcl timer_manager_$sleep entry (fixed bin (71), bit (2)); 96 dcl xmail_error_$no_code entry () options (variable); 97 dcl xmail_error_$code_first entry () options (variable); 98 dcl xmail_get_str_$yes_no entry (char (*) var, bit (1) aligned); 99 dcl xmail_select_file_ entry (char (*), char (*), char (*), bit (1) aligned, bit (1) aligned, char (168), 100 char (32) var, bit (1) aligned, bit (1) aligned, fixed bin (35)); 101 dcl xmail_validate_$curr_msgs entry (ptr, fixed bin (35)); 102 dcl xmail_validate_$mbx entry (ptr, fixed bin (35)); 103 104 /* CONSTANTS */ 105 106 dcl ACCEPT_OLD bit (1) aligned int static options (constant) init ("1"b); 107 dcl ACCEPT_NEW bit (1) aligned int static options (constant) init ("1"b); 108 dcl CURRENT bit (1) aligned int static options (constant) init ("1"b); 109 dcl MY_NAME char (16) static options (constant) init ("xmail_file_msgs_"); 110 dcl SECONDS bit (2) int static options (constant) init ("11"b); 111 dcl SINGLE bit (1) aligned int static options (constant) init ("0"b); 112 dcl SP char (1) aligned int static options (constant) init (" "); 113 dcl MORE_MSG char (12) aligned int static options (constant) init (" ... "); 114 115 /* EXTERNAL STATIC */ 116 117 dcl error_table_$badcall fixed bin (35) ext static; 118 dcl error_table_$noentry fixed bin (35) ext static; 119 dcl error_table_$rqover fixed bin (35) ext static; 120 dcl iox_$user_output ptr ext static; 121 dcl mlsys_et_$mailbox_full fixed bin (35) ext static; 122 dcl mlsys_et_$no_a_permission fixed bin (35) ext static; 123 dcl mlsys_et_$no_r_permission fixed bin (35) ext static; 124 dcl mlsys_et_$no_savebox fixed bin (35) ext static; 125 dcl mlsys_et_$savebox_created fixed bin (35) ext static; 126 dcl xmail_err_$no_curr_msgs fixed bin (35) ext static; 127 dcl xmail_err_$no_savebox fixed bin (35) ext static; 128 129 /* AUTOMATIC */ 130 131 dcl add_more_msg bit (1) aligned; 132 dcl allow_selection bit (1) aligned; 133 dcl code fixed bin (35); 134 dcl create_if_not_found bit (1) aligned; 135 dcl default_file char (32) var; 136 dcl dir char (168); 137 dcl file_mode bit (1) aligned; 138 dcl i fixed bin; 139 dcl prefix char (32) var; 140 dcl message_count fixed bin; 141 dcl message_num fixed bin; 142 dcl message_no_string char (200) var; 143 dcl message_ptr ptr init (null); 144 dcl msg_filed_sw bit (1) aligned; 145 dcl needs_filing bit (1); 146 dcl original_message_count fixed bin; 147 dcl prompt_string char (256) var; 148 dcl unused_return_length fixed bin; 149 dcl yes_sw bit (1) aligned; 150 dcl unused_bit bit (1) aligned; 151 152 dcl 1 auto_open_options like open_options; 153 dcl 1 auto_close_options like close_options; 154 155 /* BUILTIN */ 156 157 dcl (addr, char, length, ltrim, maxlength, null) 158 builtin; 159 160 /* CONDITIONS */ 161 162 dcl (quit) condition; 163 164 /* INCLUDE FILES */ 165 1 1 /* BEGIN INCLUDE FILE ... mlsys_mailbox.incl.pl1 */ 1 2 /* Created: April 1983 by G. Palter */ 1 3 1 4 /* Definition of a mailbox as used by the Multics Mail System */ 1 5 1 6 dcl 1 mailbox aligned based (mailbox_ptr), 1 7 2 version character (8) unaligned, 1 8 2 reserved bit (144), /* for exclusive use of the mail system */ 1 9 2 mailbox_address pointer, /* mail system address of this mailbox */ 1 10 2 mailbox_dirname character (168) unaligned, /* directory containing this mailbox */ 1 11 2 mailbox_ename character (32) unaligned, /* entry name of this mailbox (includes ".mbx") */ 1 12 2 mailbox_type fixed binary, /* type of mailbox (see below) */ 1 13 2 mode bit (36), /* user's effective extended access to this mailbox */ 1 14 2 flags, 1 15 3 salvaged bit (1) unaligned, /* ON => this mailbox has been salvaged since last open */ 1 16 3 reserved bit (35) unaligned, /* for exclusive use of the mail system */ 1 17 2 message_selection_mode fixed binary, /* types of messages read: all/ordinary/interactive */ 1 18 2 sender_selection_mode fixed binary, /* whose messages were read: all/own/not-own */ 1 19 2 message_reading_level fixed binary, /* how much of each message read: keys/messages */ 1 20 2 n_messages fixed binary, /* total # of messages in this mailbox structure */ 1 21 2 n_ordinary_messages fixed binary, /* ... # of ordinary messages here */ 1 22 2 n_interactive_messages fixed binary, /* ... # of interactive messages here */ 1 23 2 n_deleted_messages fixed binary, /* ... # of messages here marked for later deletion */ 1 24 2 messages (mailbox_n_messages refer (mailbox.n_messages)), 1 25 3 key bit (72), /* unique key to read this message if not already read */ 1 26 3 message_ptr pointer; /* -> the message structure */ 1 27 1 28 dcl MAILBOX_VERSION_2 character (8) static options (constant) initial ("mlsmbx02"); 1 29 1 30 dcl mailbox_ptr pointer; 1 31 1 32 dcl mailbox_n_messages fixed binary; /* for exclusive use of the mail system */ 1 33 1 34 1 35 /* Types of mailboxes distinguished by the mail system */ 1 36 1 37 dcl (USER_DEFAULT_MAILBOX initial (1), /* the user's default mailbox for receiving mail */ 1 38 USER_LOGBOX initial (2), /* the user's logbox */ 1 39 SAVEBOX initial (3), /* a savebox */ 1 40 OTHER_MAILBOX initial (4)) /* any other type of mailbox */ 1 41 fixed binary static options (constant); 1 42 1 43 /* END INCLUDE FILE ... mlsys_mailbox.incl.pl1 */ 166 167 2 1 /* BEGIN INCLUDE FILE ... mlsys_open_options.incl.pl1 */ 2 2 /* Created: June 1983 by G. Palter */ 2 3 2 4 /* Options for the mail_system_$open_mailbox entrypoint */ 2 5 2 6 dcl 1 open_options aligned based (open_options_ptr), 2 7 2 version character (8), 2 8 2 message_selection_mode fixed binary, /* what types are to be read (all/ordinary/interactive) */ 2 9 2 sender_selection_mode fixed binary, /* selects messages by who sent them */ 2 10 2 message_reading_level fixed binary; /* specifies whether all or only part of a message is read */ 2 11 2 12 dcl OPEN_OPTIONS_VERSION_2 character (8) static options (constant) initial ("mlsopn02"); 2 13 2 14 dcl open_options_ptr pointer; 2 15 2 16 2 17 dcl ALL_MESSAGES fixed binary static options (constant) initial (0); 2 18 /* read all messages in the mailbox ... 2 19* ... used as both a message and sender selection mode */ 2 20 2 21 /* Defined message selection modes */ 2 22 2 23 dcl (ORDINARY_MESSAGES initial (1), /* read only ordinary messages */ 2 24 INTERACTIVE_MESSAGES initial (2)) /* read only interactive messages */ 2 25 fixed binary static options (constant); 2 26 2 27 2 28 /* Defined sender selection modes */ 2 29 2 30 dcl (ACCESSIBLE_MESSAGES initial (-1), /* reads whatever messages are accessible */ 2 31 OWN_MESSAGES initial (1), /* reads only those messages sent by this user */ 2 32 NOT_OWN_MESSAGES initial (2)) /* reads only those messages not sent by this user */ 2 33 fixed binary static options (constant); 2 34 2 35 2 36 /* Defined message reading levels */ 2 37 2 38 dcl (READ_KEYS initial (1), /* reads only the unique key of each message */ 2 39 READ_MESSAGES initial (2)) /* reads the entire content of each message */ 2 40 fixed binary static options (constant); 2 41 2 42 /* END INCLUDE FILE ... mlsys_open_options.incl.pl1 */ 168 169 3 1 /* BEGIN INCLUDE FILE ... mlsys_close_options.incl.pl1 */ 3 2 /* Created: June 1983 by G. Palter */ 3 3 3 4 /* Options for the mail_system_$close_mailbox entrypoint */ 3 5 3 6 dcl 1 close_options aligned based (close_options_ptr), 3 7 2 version character (8) unaligned, 3 8 2 flags, 3 9 3 perform_deletions bit (1) unaligned, /* ON => perform deletions requested earlier */ 3 10 3 report_deletion_errors bit (1) unaligned, /* ON => report problems deleting via sub_err_ */ 3 11 3 mbz bit (34) unaligned; /* must be set to ""b by the caller */ 3 12 3 13 dcl CLOSE_OPTIONS_VERSION_2 character (8) static options (constant) initial ("mlsclo02"); 3 14 3 15 dcl close_options_ptr pointer; 3 16 3 17 /* END INCLUDE FILE ... mlsys_close_options.incl.pl1 */ 170 171 4 1 /* begin include fine window_dcls.incl.pl1 BIM June 1981 */ 4 2 /* Modified 9 October 1983 by Jon A. Rochlis to add window_$edit_line. */ 4 3 4 4 /* format: style3 */ 4 5 4 6 declare window_$bell entry (pointer, fixed binary (35)); 4 7 declare window_$clear_region 4 8 entry (pointer, fixed binary, fixed binary, fixed binary, fixed binary, fixed binary (35)); 4 9 declare window_$clear_to_end_of_line 4 10 entry (pointer, fixed binary (35)); 4 11 declare window_$clear_to_end_of_window 4 12 entry (pointer, fixed binary (35)); 4 13 declare window_$clear_window 4 14 entry (pointer, fixed binary (35)); 4 15 declare window_$delete_chars 4 16 entry (pointer, fixed binary, fixed binary (35)); 4 17 declare window_$get_cursor_position 4 18 entry (pointer, fixed binary, fixed binary, fixed binary (35)); 4 19 4 20 /* Call window_$get_echoed_chars (iocb_ptr, n_to_read, read_buffer, n_read, read_break, code); */ 4 21 4 22 declare window_$get_echoed_chars 4 23 entry (pointer, fixed binary (21), character (*), fixed binary (21), character (1) var, 4 24 fixed binary (35)); 4 25 declare window_$get_unechoed_chars 4 26 entry (pointer, fixed binary (21), character (*), fixed binary (21), character (1) var, 4 27 fixed binary (35)); 4 28 declare window_$insert_text entry (pointer, character (*), fixed binary (35)); 4 29 declare window_$overwrite_text 4 30 entry (pointer, character (*), fixed binary (35)); 4 31 declare window_$position_cursor 4 32 entry (pointer, fixed binary, fixed binary, fixed binary (35)); 4 33 4 34 /* Call window_$position_cursor_rel (iocb_ptr, delta_line, delta_column, code); */ 4 35 4 36 declare window_$position_cursor_rel 4 37 entry (pointer, fixed binary, fixed binary, fixed binary (35)); 4 38 4 39 /* Call window_$scroll_region (iocb_ptr, first_line_of_region, n_lines_of_region, distance_to_scroll_region_negative_is_up, 4 40* code); */ 4 41 4 42 declare window_$scroll_region 4 43 entry (pointer, fixed binary, fixed binary, fixed binary, fixed binary (35)); 4 44 declare window_$sync entry (pointer, fixed binary (35)); 4 45 4 46 /* Call window_$write_raw_text (iocb_ptr, text_string, code); */ 4 47 4 48 declare window_$write_raw_text 4 49 entry (pointer, character (*), fixed binary (35)); 4 50 4 51 /* Call window_$write_sync_read (iocb_ptr, prompt_string, n_to_read, read_buffer, n_read, break_char, code); */ 4 52 4 53 declare window_$write_sync_read 4 54 entry (pointer, character (*), fixed bin (21), character (*), fixed binary (21), 4 55 character (1) var, fixed binary (35)); 4 56 4 57 /* Call window_$change_line (iocb_ptr, new_line, code); */ 4 58 4 59 declare window_$change_line entry (pointer, fixed binary, fixed binary (35)); 4 60 4 61 /* Call window_$change_column (iocb_ptr, new_column, code); */ 4 62 4 63 declare window_$change_column 4 64 entry (pointer, fixed binary, fixed binary (35)); 4 65 4 66 /* Call window_$get_one_unechoed (iocb_ptr, char_or_len_0, block_flag, code); */ 4 67 declare ( 4 68 window_$get_one_unechoed, 4 69 window_$get_one_unechoed_char 4 70 ) entry (pointer, character (1) var, bit (1) aligned, fixed binary (35)); 4 71 4 72 declare window_$create entry (pointer, pointer, pointer, fixed binary (35)); 4 73 4 74 declare window_$destroy entry (pointer, fixed binary (35)); 4 75 4 76 declare window_$edit_line entry (pointer, pointer, pointer, fixed bin(21), fixed bin(21), fixed bin(35)); 4 77 4 78 /* call window_$edit_line (iocb_ptr, window_edit_line_info_ptr, buffer_ptr, 4 79* buffer_len, n_returned, code); */ 4 80 4 81 4 82 /* end include file window_dcls.incl.pl1 */ 172 173 5 1 /* Created 06/17/81 by Suzanne Krupp */ 5 2 5 3 dcl n_messages fixed bin; 5 4 dcl MSG_STRUCT_VERSION_1 fixed bin int static options(constant) init(1); 5 5 5 6 dcl curr_msgsp ptr; 5 7 5 8 dcl 1 curr_msgs based(curr_msgsp), 5 9 2 version fixed bin, 5 10 2 count fixed bin, 5 11 2 numbers (n_messages refer(curr_msgs.count)) fixed bin; 5 12 5 13 dcl nonexist_msgsp ptr; 5 14 5 15 dcl 1 nonexist_msgs based(nonexist_msgsp), 5 16 2 version fixed bin, 5 17 2 count fixed bin, 5 18 2 numbers (n_messages refer(nonexist_msgs.count)) fixed bin; 5 19 5 20 dcl msg_structp ptr; 5 21 5 22 dcl 1 msg_struct based(msg_structp), 5 23 2 version fixed bin, 5 24 2 count fixed bin, 5 25 2 numbers(n_messages refer(msg_struct.count)) fixed bin; 175 6 1 /* BEGIN INCLUDE FILE: xmail_data.incl.pl1 */ 6 2 6 3 6 4 /****^ HISTORY COMMENTS: 6 5* 1) change(85-12-20,Blair), approve(86-03-06,MCR7358), 6 6* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 7* Modified 03/15/85 by Joanne Backs adding confirm_print flag. 6 8* 2) change(85-12-20,LJAdams), approve(86-03-06,MCR7358), 6 9* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 10* Adding switch to indicate request for menu display came from general help. 6 11* This is so general help menu will be displayed in top screen. 6 12* 3) change(86-01-10,Blair), approve(86-03-06,MCR7358), 6 13* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 14* Add switch to indicate whether or not it is permissible to process mail 6 15* in other users' mailboxes (foreign_mailbox). 6 16* 4) change(86-01-13,Blair), approve(86-03-06,MCR7358), 6 17* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 18* Add bit to indicate whether or not this is a true cleanup condition. 6 19* 5) change(86-02-06,Blair), approve(86-03-06,MCR7358), 6 20* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 21* Rearrange to group all the bit flags together in one word with a pad. 6 22* 6) change(86-03-05,Blair), approve(86-03-05,MCR7358), 6 23* audit(86-04-21,RBarstad), install(86-05-28,MR12.0-1062): 6 24* Change value_seg ptr to value_seg_pathname to avoid the situation where 6 25* you keep around a pointer to a structure which no longer exists. 6 26* 7) change(87-01-16,Blair), approve(87-02-05,MCR7618), 6 27* audit(87-04-15,RBarstad), install(87-04-26,MR12.1-1025): 6 28* Add a field to indicate whether or not we should process interactive msgs. 6 29* Increment version to 4.1 so default value will get set. 6 30* 8) change(87-02-13,Blair), approve(87-02-13,MCR7618), 6 31* audit(87-04-15,RBarstad), install(87-04-26,MR12.1-1025): 6 32* Add a field to indicate whether or not we're processing a reply so that we 6 33* will be able to rebuild the screens properly after a disconnect occurs. 6 34* Error_list #114. 6 35* 9) change(88-07-26,Blair), approve(88-07-26,MCR7959), 6 36* audit(88-08-25,RBarstad), install(88-09-02,MR12.2-1098): 6 37* Add a bit to indicate whether or not the error segment had to be created 6 38* in the pdir (because we didn't have sma access to the mlsys_dir). 6 39* END HISTORY COMMENTS */ 6 40 6 41 6 42 /* Written 5/13/81 by Paul H. Kyzivat */ 6 43 /* Modified 12/16/81 by S. Krupp to delete unused parts of structure 6 44* and to add n_fkeys_used */ 6 45 /* Modified 12/14/82 by Dave Schimke to make the xmail version a 10 character 6 46* varying string. */ 6 47 /* Modified 09/12/83 by Dave Schimke adding interactive_msgs flag */ 6 48 /* Modified 09/14/83 by Dave Schimke adding moved_user_io */ 6 49 /* Modified 09/06/84 by Joanne Backs adding lists_as_menus flag */ 6 50 /* Modified 09/21/84 by Joanne Backs adding remove_menus flag */ 6 51 6 52 dcl xmail_data_ptr external static ptr init (null); 6 53 6 54 dcl 1 xmail_data aligned based (xmail_data_ptr), 6 55 2 mail_dir char (168) varying, 6 56 2 first_label label, 6 57 2 quit_label label, 6 58 2 value_seg_pathname char (168) varying, 6 59 2 moved_user_io ptr, 6 60 2 normal_usage char (80) unal, 6 61 2 function_key_info, 6 62 3 function_key_data_ptr ptr, 6 63 3 n_fkeys_used fixed bin, 6 64 2 actee, 6 65 3 person char(32) varying, 6 66 3 project char(32) varying, 6 67 2 flags aligned, 6 68 3 mail_in_incoming bit (1) unal, 6 69 3 lists_as_menus bit (1) unal, /* personalization */ 6 70 3 remove_menus bit (1) unal, /* personalization */ 6 71 3 confirm_print bit (1) unal, /* personalization */ 6 72 3 multics_mode bit (1) unal, /* personalization */ 6 73 3 interactive_msgs bit (1) unal, /* personalization */ 6 74 3 foreign_mailbox bit (1) unal, /* read others' mailboxes */ 6 75 3 general_help bit (1) unal, /* indicated requesting gen help*/ 6 76 3 cleanup_signalled bit (1) unal, /* on when true cleanup condition */ 6 77 3 msgs_as_mail bit (1) unal, /* on for include_msgs */ 6 78 3 reply_request bit (1) unal, /* on if we're doing a reply */ 6 79 3 error_seg_in_pdir bit (1) unal, /* on if the error_seg is in the pdir */ 6 80 3 pad bit (24) unal; 6 81 6 82 6 83 6 84 dcl xmail_version char(10) var static options(constant) init("4.1"); 6 85 6 86 /* END INCLUDE FILE: xmail_data.incl.pl1 */ 176 177 178 /* BEGIN */ 179 180 call xmail_error_$code_first (error_table_$badcall, MY_NAME, "q", 181 "This is an internal programming error."); 182 183 /* ENTRY POINTS */ 184 185 current_msgs: entry (P_mailbox_ptr, P_curr_msgsp, P_default_file, P_allow_selection); 186 187 /* * * * * * * * * * * * * * * * * * * * * * * * * * 188* 189* This entrypoint attempts to file all messages in the current message 190* structure. If P_allow_selection is "on", the user is prompted for a 191* mailfile to file into with P_default_file (if given) as the default 192* choice. It is invalid to call this entry with P_allow_selection "off" 193* and P_default_file = "". 194* The main work is done by the call to the file_message internal proc. 195* On mailbox_full error, the user is informed, the messages already filed 196* are backed out, and processing aborted by calling xmail_error_. This 197* signals quit and returns to the menu. 198* On any other error, file_message prints the messages that have 199* successfully been filed and then aborts by calling xmail_error_. 200* 201* * * * * * * * * * * * * * * * * * * * * * * * * */ 202 203 call xmail_validate_$mbx (P_mailbox_ptr, code); 204 if code ^= 0 205 then call xmail_error_$no_code (code, MY_NAME, "q", "Invalid mailbox structure. This is an internal programming error."); 206 207 if P_curr_msgsp = null 208 then call xmail_error_$code_first (xmail_err_$no_curr_msgs, MY_NAME, "i"); 209 else do; 210 call xmail_validate_$curr_msgs (P_curr_msgsp, code); 211 if code ^= 0 212 then call xmail_error_$no_code (code, MY_NAME, "q", "Invalid message structure. This is an internal programming error."); 213 214 end; 215 216 curr_msgsp = P_curr_msgsp; 217 mailbox_ptr = P_mailbox_ptr; 218 default_file = P_default_file; 219 allow_selection = P_allow_selection; 220 file_mode = CURRENT; 221 msg_filed_sw = "0"b; 222 223 if allow_selection then do; 224 call xmail_select_file_ ("mail file", "sv.mbx", (default_file), ACCEPT_OLD, ACCEPT_NEW, dir, prefix, create_if_not_found, unused_bit, code); 225 if code ^= 0 then go to CURRENT_EXIT; /* Diagnostic msg already issued by xmail_select_file_. */ 226 end; 227 else do; /* for archive etc */ 228 dir = xmail_data.mail_dir; 229 prefix = default_file; 230 create_if_not_found = "1"b; 231 end; 232 233 message_no_string = ""; 234 add_more_msg = "0"b; 235 message_count = curr_msgs.count; 236 237 /* If there is more than 1 message, save total count of messages before 238* filing in case mail file becomes full and messages have to be deleted. */ 239 240 if message_count > 1 241 then call save_message_count; 242 243 /* Loop for every message to be filed */ 244 245 do i = 1 to curr_msgs.count; 246 message_num = curr_msgs.numbers (i); 247 if mailbox.messages (message_num).message_ptr = null 248 then do; 249 call mail_system_$read_message (mailbox_ptr, message_num, code); 250 if code ^= 0 251 then call xmail_error_$no_code (code, MY_NAME, "l", "Unable to read message ^d. This is an internal programming error.", message_num); 252 end; 253 message_ptr = mailbox.messages (message_num).message_ptr; 254 call file_message; /* this call does the work */ 255 if length (message_no_string) + length (ltrim (char (message_num))) + length (SP) > maxlength (message_no_string) 256 then add_more_msg = "1"b; 257 else message_no_string = message_no_string || ltrim (char (message_num)) || SP; 258 end; 259 260 if msg_filed_sw 261 then call print_filed_msg; 262 P_default_file = prefix; 263 264 CURRENT_EXIT: 265 return; 266 267 single_msg: entry (P_msg_ptr, P_default_file, P_allow_selection); 268 269 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 270 /* */ 271 /* This entry point performs the same function as the above entry except that */ 272 /* it takes a single message ptr as input and files only that message. This */ 273 /* allows send_message, reply_message etc. to call a common routine for filing. */ 274 /* */ 275 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 276 277 278 279 file_mode = SINGLE; 280 msg_filed_sw = "0"b; 281 282 message_count = 1; /* always 1 in case of problems in filing */ 283 message_ptr = P_msg_ptr; 284 default_file = P_default_file; 285 allow_selection = P_allow_selection; 286 287 if allow_selection then do; 288 call xmail_select_file_ ("mail file", "sv.mbx", (default_file), ACCEPT_OLD, ACCEPT_NEW, dir, prefix, create_if_not_found, unused_bit, code); 289 if code ^= 0 then go to SINGLE_EXIT; /* Diagnostic msg already issued by xmail_select_file_. */ 290 end; 291 else do; /* for archive etc */ 292 dir = xmail_data.mail_dir; 293 prefix = default_file; 294 create_if_not_found = "1"b; 295 end; 296 297 call file_message; 298 299 if msg_filed_sw 300 then call ioa_ ("Message filed in ""^a"".", prefix); 301 P_default_file = prefix; 302 303 SINGLE_EXIT: 304 305 return; 306 307 original_and_reply: entry (P_orig_msg_ptr, P_reply_msg_ptr, P_default_file, P_allow_selection); 308 309 310 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 311 /* */ 312 /* This entry point performs the same function as the above entry except that it takes */ 313 /* two message pointers as input; the pointer to the original message and the pointer to */ 314 /* the message created from the reply. This entry is called only by reply_message when */ 315 /* the original is to be filed before the reply. Because of the need to preserve backing */ 316 /* out previously filed messages when a file is full ( which makes two calls to */ 317 /* single_msg useless), and the fact that both messages aren't in the same mailbox) this */ 318 /* entry point seems to be the only alternative. */ 319 /* */ 320 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 321 322 file_mode = SINGLE; 323 324 msg_filed_sw = "0"b; 325 message_count = 1; 326 message_ptr = P_orig_msg_ptr; 327 default_file = P_default_file; 328 allow_selection = P_allow_selection; 329 330 if allow_selection then do; 331 call xmail_select_file_ ("mail file", "sv.mbx", (default_file), ACCEPT_OLD, ACCEPT_NEW, dir, prefix,create_if_not_found, unused_bit, code); 332 if code ^= 0 then go to ORIG_AND_REPLY_EXIT; 333 end; 334 else do; 335 dir = xmail_data.mail_dir; 336 prefix = default_file; 337 create_if_not_found = "1"b; 338 end; 339 340 call file_message; 341 if msg_filed_sw 342 then call ioa_ ("Original filed in ""^a"".", prefix); 343 else 344 call ioa_ ("Original was not filed."); 345 346 message_count = 2; 347 message_ptr = P_reply_msg_ptr; 348 msg_filed_sw = "0"b; 349 350 call file_message; 351 if msg_filed_sw 352 then do; 353 call ioa_ ("Message filed in ""^a"".", prefix); 354 P_default_file = prefix; 355 end; 356 else 357 P_default_file = ""; 358 359 360 ORIG_AND_REPLY_EXIT: 361 362 return; 363 364 /* INTERNAL PROCEDURES */ 365 366 file_message: proc; 367 368 369 needs_filing = "1"b; 370 do while (needs_filing); 371 call mail_system_$save_message (message_ptr, dir, (prefix), create_if_not_found, code); 372 if code = 0 373 then do; 374 needs_filing = "0"b; 375 msg_filed_sw = "1"b; 376 end; 377 378 else if code = mlsys_et_$no_savebox 379 then do; 380 call ioa_$rsnnl ("The specified mail file ""^a"" does not exist.^/Do you wish to create it? ", prompt_string, unused_return_length, prefix); 381 call xmail_get_str_$yes_no (prompt_string, yes_sw); 382 if yes_sw then create_if_not_found = "1"b; 383 else if xmail_data.cleanup_signalled 384 then call xmail_error_$no_code (xmail_err_$no_savebox, MY_NAME, "i", 385 "No messages have been filed."); 386 else do; 387 call xmail_error_$no_code (xmail_err_$no_savebox, MY_NAME, "c", "No messages have been filed."); 388 needs_filing = "0"b; 389 msg_filed_sw = "0"b; 390 P_default_file = ""; 391 goto CURRENT_EXIT; 392 end; 393 end; 394 395 else if code = mlsys_et_$savebox_created 396 then do; 397 call ioa_ ("The mail file ""^a"" has been created.", prefix); 398 msg_filed_sw = "1"b; 399 needs_filing = "0"b; 400 end; 401 402 /* If directory or file has become full, inform user and backout previosly 403* filed messages if no. of messages was greater than one. */ 404 405 else if code = error_table_$rqover 406 then do; 407 if message_count = 1 408 then call xmail_error_$no_code (code, MY_NAME, "q", "Unable to file message. Your directory is full."); 409 else do; 410 call ioa_ ("Unable to continue filing. Your directory is full."); 411 call backout_filed_msg; 412 call xmail_error_$no_code (code, MY_NAME, "q", "Filing terminated because the directory was full.^/ No messages were filed."); 413 end; 414 end; 415 416 else if code = mlsys_et_$mailbox_full 417 then do; 418 if message_count = 1 419 then call xmail_error_$no_code (code, MY_NAME, "q", "Unable to file message. The ""^a"" file is full.", prefix); 420 else do; 421 call ioa_ ("Unable to continue filing. The ""^a"" file is full.", prefix); 422 call backout_filed_msg; 423 call xmail_error_$no_code (code, MY_NAME, "q", "Filing terminated because the ""^a"" file was full.^/ No messages were filed.", prefix); 424 end; 425 end; 426 427 else if code = mlsys_et_$no_a_permission 428 then call xmail_error_$no_code (code, MY_NAME, "q", " Unable to file message. You do not have access to the ""^a"" mail file.", prefix); 429 430 else do; 431 if file_mode = CURRENT then do; 432 call print_filed_msg; 433 call xmail_error_$no_code (code, MY_NAME, "q", "Unable to file msg^[ ^d.^;.^] This is an internal programming error.", (message_num > 0), message_num); 434 end; 435 else call xmail_error_$no_code (code, MY_NAME, "q", "Unable to file msg. This is an internal programming error."); 436 needs_filing = "0"b; 437 end; 438 end; /* while need filing */ 439 440 end file_message; 441 442 print_filed_msg: proc; 443 444 /* Lists the messages that have been successfully filed. */ 445 446 call ioa_ ("Message^[s^;^] ^a ^[^a^;^s^] filed in ""^a"".", (curr_msgs.count > 1), message_no_string, add_more_msg, MORE_MSG, prefix); 447 end print_filed_msg; 448 449 save_message_count: proc (); 450 451 /* This new internal procedure will save the original message count where 452* messages are to be filed, to be used in case file becomes full */ 453 454 dcl smc_code fixed binary (35); 455 456 /* BEGIN */ 457 458 smc_code = 0; 459 original_message_count = 0; 460 461 call mail_system_$get_message_counts (dir, (prefix || ".sv"), "1"b, (0), original_message_count, (0), smc_code); 462 if smc_code = mlsys_et_$no_r_permission 463 then call xmail_error_$no_code (smc_code, MY_NAME, "q", "You do not have access to read the ""^a"" mail file.", prefix); 464 else if smc_code = error_table_$noentry 465 then original_message_count = 0; 466 else if smc_code ^= 0 467 then call xmail_error_$no_code (smc_code, MY_NAME, "q", "Unable to determine message count on ""^a"" mail file. This file cannot be used.", prefix); 468 return; 469 470 end save_message_count; 471 472 backout_filed_msg: proc (); 473 474 /* This new internal procedure will delete all the current messages, if more 475* than one, that were filed just before the mailbox full error. It uses the 476* original message count determined in save_message_count proc. */ 477 478 dcl bfm_code fixed binary (35); 479 dcl bfm_mailbox_ptr ptr; 480 dcl bfm_message_ptr ptr; 481 482 /* BEGIN */ 483 484 call ioa_ ("^/ Backing out partially stored messages. This may take awhile..."); 485 bfm_code = 0; 486 bfm_mailbox_ptr = null (); 487 bfm_message_ptr = null (); 488 489 on condition (quit) 490 begin; 491 if bfm_mailbox_ptr ^= null () 492 then do; 493 call ioa_ ("Closing file. Partially stored messages may not be all backed out."); 494 call close_file; 495 end; 496 call continue_to_signal_ ((0)); 497 end; 498 499 /* Set up to open mailbox to discard the already filed messages. */ 500 501 if xmail_data.msgs_as_mail then 502 auto_open_options.message_selection_mode = ALL_MESSAGES; 503 else auto_open_options.message_selection_mode = ORDINARY_MESSAGES; 504 auto_open_options.version = OPEN_OPTIONS_VERSION_2; 505 auto_open_options.sender_selection_mode = ACCESSIBLE_MESSAGES; 506 auto_open_options.message_reading_level = READ_KEYS; 507 508 call mail_system_$open_mailbox (dir, (prefix || ".sv"), addr (auto_open_options), MAILBOX_VERSION_2, bfm_mailbox_ptr, bfm_code); 509 if bfm_code ^= 0 510 then call xmail_error_$no_code (bfm_code, MY_NAME, "q", "Unable to open ""^a"" mail file to backout partially filed messages.", prefix); 511 512 do i = original_message_count + 1 to bfm_mailbox_ptr -> mailbox.n_messages; 513 if bfm_mailbox_ptr -> mailbox.messages (i).message_ptr = null () 514 then do; 515 call mail_system_$read_message (bfm_mailbox_ptr, i, bfm_code); 516 if bfm_code ^= 0 517 then call xmail_error_$no_code (bfm_code, MY_NAME, "l", "Unable to read message ^d while backing out partially filed messages.", i); 518 end; 519 bfm_message_ptr = bfm_mailbox_ptr -> mailbox.messages (i).message_ptr; 520 call mail_system_$mark_message_for_deletion (bfm_message_ptr, bfm_code); 521 if bfm_code ^= 0 522 then call xmail_error_$no_code (bfm_code, MY_NAME, "l", "Unable to backout filed message ^d from ""^a"" mail file.", i, prefix); 523 end; 524 525 /* After all messages are discarded, close mailbox, which will actually delete 526* the messages, then clear window */ 527 528 call close_file; 529 call timer_manager_$sleep (4, SECONDS); /* give user time to read */ 530 call window_$clear_window (iox_$user_output, (0));/* ignore code */ 531 return; 532 533 close_file: proc; 534 535 /* Internal procedure to close mail file that was opened to delete messages. 536* Called from backout_filed_msg and if quit during backout_filed_msg. */ 537 538 auto_close_options.version = CLOSE_OPTIONS_VERSION_2; 539 auto_close_options.flags.perform_deletions = "1"b; 540 auto_close_options.flags.report_deletion_errors = "0"b; 541 auto_close_options.flags.mbz = "0"b; 542 543 call mail_system_$close_mailbox (bfm_mailbox_ptr, addr (auto_close_options), bfm_code); 544 if bfm_code ^= 0 545 then call xmail_error_$no_code (bfm_code, MY_NAME, "l", "Unable to close ""^a"" mail file after backing out partially filed messages.", prefix); 546 return; 547 548 end close_file; 549 550 end backout_filed_msg; 551 552 end xmail_file_msgs_; 553 SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 09/02/88 0745.0 xmail_file_msgs_.pl1 >spec>install>MR12.2-1098>xmail_file_msgs_.pl1 166 1 10/27/83 2104.2 mlsys_mailbox.incl.pl1 >ldd>include>mlsys_mailbox.incl.pl1 168 2 10/27/83 2104.2 mlsys_open_options.incl.pl1 >ldd>include>mlsys_open_options.incl.pl1 170 3 10/27/83 2104.2 mlsys_close_options.incl.pl1 >ldd>include>mlsys_close_options.incl.pl1 172 4 09/12/84 0916.7 window_dcls.incl.pl1 >ldd>include>window_dcls.incl.pl1 174 5 06/08/82 1329.4 xmail_curr_msg_info.incl.pl1 >ldd>include>xmail_curr_msg_info.incl.pl1 176 6 09/02/88 0743.4 xmail_data.incl.pl1 >spec>install>MR12.2-1098>xmail_data.incl.pl1 NAMES DECLARED IN THIS COMPILATION. IDENTIFIER OFFSET LOC STORAGE CLASS DATA TYPE ATTRIBUTES AND REFERENCES (* indicates a set context) NAMES DECLARED BY DECLARE STATEMENT. ACCEPT_NEW 000050 constant bit(1) initial dcl 107 set ref 224* 288* 331* ACCEPT_OLD 000050 constant bit(1) initial dcl 106 set ref 224* 288* 331* ACCESSIBLE_MESSAGES constant fixed bin(17,0) initial dcl 2-30 ref 505 ALL_MESSAGES constant fixed bin(17,0) initial dcl 2-17 ref 501 CLOSE_OPTIONS_VERSION_2 000000 constant char(8) initial packed unaligned dcl 3-13 ref 538 CURRENT constant bit(1) initial dcl 108 ref 220 431 MAILBOX_VERSION_2 000004 constant char(8) initial packed unaligned dcl 1-28 set ref 508* MORE_MSG 000006 constant char(12) initial dcl 113 set ref 446* MY_NAME 000012 constant char(16) initial packed unaligned dcl 109 set ref 180* 204* 207* 211* 250* 383* 387* 407* 412* 418* 423* 427* 433* 435* 462* 466* 509* 516* 521* 544* OPEN_OPTIONS_VERSION_2 000002 constant char(8) initial packed unaligned dcl 2-12 ref 504 ORDINARY_MESSAGES constant fixed bin(17,0) initial dcl 2-23 ref 503 P_allow_selection parameter bit(1) dcl 79 ref 185 219 267 285 307 328 P_curr_msgsp parameter pointer dcl 73 set ref 185 207 210* 216 P_default_file parameter varying char(32) dcl 74 set ref 185 218 262* 267 284 301* 307 327 354* 356* 390* P_mailbox_ptr parameter pointer dcl 75 set ref 185 203* 217 P_msg_ptr parameter pointer dcl 76 ref 267 283 P_orig_msg_ptr parameter pointer dcl 77 ref 307 326 P_reply_msg_ptr parameter pointer dcl 78 ref 307 347 READ_KEYS constant fixed bin(17,0) initial dcl 2-38 ref 506 SECONDS 000011 constant bit(2) initial packed unaligned dcl 110 set ref 529* SINGLE constant bit(1) initial dcl 111 ref 279 322 SP 004112 constant char(1) initial dcl 112 ref 255 257 add_more_msg 000100 automatic bit(1) dcl 131 set ref 234* 255* 446* addr builtin function dcl 157 ref 508 508 543 543 allow_selection 000101 automatic bit(1) dcl 132 set ref 219* 223 285* 287 328* 330 auto_close_options 000406 automatic structure level 1 packed packed unaligned dcl 153 set ref 543 543 auto_open_options 000401 automatic structure level 1 unaligned dcl 152 set ref 508 508 bfm_code 000100 automatic fixed bin(35,0) dcl 478 set ref 485* 508* 509 509* 515* 516 516* 520* 521 521* 543* 544 544* bfm_mailbox_ptr 000102 automatic pointer dcl 479 set ref 486* 491 508* 512 513 515* 519 543* bfm_message_ptr 000104 automatic pointer dcl 480 set ref 487* 519* 520* char builtin function dcl 157 ref 255 257 cleanup_signalled 213(08) based bit(1) level 3 packed packed unaligned dcl 6-54 ref 383 close_options based structure level 1 dcl 3-6 code 000102 automatic fixed bin(35,0) dcl 133 set ref 203* 204 204* 210* 211 211* 224* 225 249* 250 250* 288* 289 331* 332 371* 372 378 395 405 407* 412* 416 418* 423* 427 427* 433* 435* continue_to_signal_ 000010 constant entry external dcl 86 ref 496 count 1 based fixed bin(17,0) level 2 dcl 5-8 ref 235 245 446 create_if_not_found 000103 automatic bit(1) dcl 134 set ref 224* 230* 288* 294* 331* 337* 371* 382* curr_msgs based structure level 1 unaligned dcl 5-8 curr_msgsp 000414 automatic pointer dcl 5-6 set ref 216* 235 245 246 446 default_file 000104 automatic varying char(32) dcl 135 set ref 218* 224 229 284* 288 293 327* 331 336 dir 000115 automatic char(168) packed unaligned dcl 136 set ref 224* 228* 288* 292* 331* 335* 371* 461* 508* error_table_$badcall 000050 external static fixed bin(35,0) dcl 117 set ref 180* error_table_$noentry 000052 external static fixed bin(35,0) dcl 118 ref 464 error_table_$rqover 000054 external static fixed bin(35,0) dcl 119 ref 405 file_mode 000167 automatic bit(1) dcl 137 set ref 220* 279* 322* 431 flags 2 000406 automatic structure level 2 in structure "auto_close_options" packed packed unaligned dcl 153 in procedure "xmail_file_msgs_" flags 213 based structure level 2 in structure "xmail_data" dcl 6-54 in procedure "xmail_file_msgs_" i 000170 automatic fixed bin(17,0) dcl 138 set ref 245* 246* 512* 513 515* 516* 519 521* ioa_ 000012 constant entry external dcl 87 ref 299 341 343 353 397 410 421 446 484 493 ioa_$rsnnl 000014 constant entry external dcl 88 ref 380 iox_$user_output 000056 external static pointer dcl 120 set ref 530* length builtin function dcl 157 ref 255 255 255 ltrim builtin function dcl 157 ref 255 257 mail_dir based varying char(168) level 2 dcl 6-54 ref 228 292 335 mail_system_$close_mailbox 000016 constant entry external dcl 89 ref 543 mail_system_$get_message_counts 000020 constant entry external dcl 90 ref 461 mail_system_$mark_message_for_deletion 000022 constant entry external dcl 91 ref 520 mail_system_$open_mailbox 000024 constant entry external dcl 92 ref 508 mail_system_$read_message 000026 constant entry external dcl 93 ref 249 515 mail_system_$save_message 000030 constant entry external dcl 94 ref 371 mailbox based structure level 1 dcl 1-6 mailbox_ptr 000412 automatic pointer dcl 1-30 set ref 217* 247 249* 253 maxlength builtin function dcl 157 ref 255 mbz 2(02) 000406 automatic bit(34) level 3 packed packed unaligned dcl 153 set ref 541* message_count 000202 automatic fixed bin(17,0) dcl 140 set ref 235* 240 282* 325* 346* 407 418 message_no_string 000204 automatic varying char(200) dcl 142 set ref 233* 255 255 257* 257 446* message_num 000203 automatic fixed bin(17,0) dcl 141 set ref 246* 247 249* 250* 253 255 257 433 433* message_ptr 106 based pointer array level 3 in structure "mailbox" dcl 1-6 in procedure "xmail_file_msgs_" ref 247 253 513 519 message_ptr 000270 automatic pointer initial dcl 143 in procedure "xmail_file_msgs_" set ref 143* 253* 283* 326* 347* 371* message_reading_level 4 000401 automatic fixed bin(17,0) level 2 dcl 152 set ref 506* message_selection_mode 2 000401 automatic fixed bin(17,0) level 2 dcl 152 set ref 501* 503* messages 104 based structure array level 2 dcl 1-6 mlsys_et_$mailbox_full 000060 external static fixed bin(35,0) dcl 121 ref 416 mlsys_et_$no_a_permission 000062 external static fixed bin(35,0) dcl 122 ref 427 mlsys_et_$no_r_permission 000064 external static fixed bin(35,0) dcl 123 ref 462 mlsys_et_$no_savebox 000066 external static fixed bin(35,0) dcl 124 ref 378 mlsys_et_$savebox_created 000070 external static fixed bin(35,0) dcl 125 ref 395 msg_filed_sw 000272 automatic bit(1) dcl 144 set ref 221* 260 280* 299 324* 341 348* 351 375* 389* 398* msgs_as_mail 213(09) based bit(1) level 3 packed packed unaligned dcl 6-54 ref 501 n_messages 100 based fixed bin(17,0) level 2 dcl 1-6 ref 512 needs_filing 000273 automatic bit(1) packed unaligned dcl 145 set ref 369* 370 374* 388* 399* 436* null builtin function dcl 157 ref 143 207 247 486 487 491 513 numbers 2 based fixed bin(17,0) array level 2 dcl 5-8 ref 246 open_options based structure level 1 dcl 2-6 original_message_count 000274 automatic fixed bin(17,0) dcl 146 set ref 459* 461* 464* 512 perform_deletions 2 000406 automatic bit(1) level 3 packed packed unaligned dcl 153 set ref 539* prefix 000171 automatic varying char(32) dcl 139 set ref 224* 229* 262 288* 293* 299* 301 331* 336* 341* 353* 354 371 380* 397* 418* 421* 423* 427* 446* 461 462* 466* 508 509* 521* 544* prompt_string 000275 automatic varying char(256) dcl 147 set ref 380* 381* quit 000000 stack reference condition dcl 162 ref 489 report_deletion_errors 2(01) 000406 automatic bit(1) level 3 packed packed unaligned dcl 153 set ref 540* sender_selection_mode 3 000401 automatic fixed bin(17,0) level 2 dcl 152 set ref 505* smc_code 000446 automatic fixed bin(35,0) dcl 454 set ref 458* 461* 462 462* 464 466 466* timer_manager_$sleep 000032 constant entry external dcl 95 ref 529 unused_bit 000400 automatic bit(1) dcl 150 set ref 224* 288* 331* unused_return_length 000376 automatic fixed bin(17,0) dcl 148 set ref 380* version 000401 automatic char(8) level 2 in structure "auto_open_options" packed packed unaligned dcl 152 in procedure "xmail_file_msgs_" set ref 504* version 000406 automatic char(8) level 2 in structure "auto_close_options" packed packed unaligned dcl 153 in procedure "xmail_file_msgs_" set ref 538* window_$clear_window 000076 constant entry external dcl 4-13 ref 530 xmail_data based structure level 1 dcl 6-54 xmail_data_ptr 000100 external static pointer initial dcl 6-52 ref 228 292 335 383 501 xmail_err_$no_curr_msgs 000072 external static fixed bin(35,0) dcl 126 set ref 207* xmail_err_$no_savebox 000074 external static fixed bin(35,0) dcl 127 set ref 383* 387* xmail_error_$code_first 000036 constant entry external dcl 97 ref 180 207 xmail_error_$no_code 000034 constant entry external dcl 96 ref 204 211 250 383 387 407 412 418 423 427 433 435 462 466 509 516 521 544 xmail_get_str_$yes_no 000040 constant entry external dcl 98 ref 381 xmail_select_file_ 000042 constant entry external dcl 99 ref 224 288 331 xmail_validate_$curr_msgs 000044 constant entry external dcl 101 ref 210 xmail_validate_$mbx 000046 constant entry external dcl 102 ref 203 yes_sw 000377 automatic bit(1) dcl 149 set ref 381* 382 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. INTERACTIVE_MESSAGES internal static fixed bin(17,0) initial dcl 2-23 MSG_STRUCT_VERSION_1 internal static fixed bin(17,0) initial dcl 5-4 NOT_OWN_MESSAGES internal static fixed bin(17,0) initial dcl 2-30 OTHER_MAILBOX internal static fixed bin(17,0) initial dcl 1-37 OWN_MESSAGES internal static fixed bin(17,0) initial dcl 2-30 READ_MESSAGES internal static fixed bin(17,0) initial dcl 2-38 SAVEBOX internal static fixed bin(17,0) initial dcl 1-37 USER_DEFAULT_MAILBOX internal static fixed bin(17,0) initial dcl 1-37 USER_LOGBOX internal static fixed bin(17,0) initial dcl 1-37 close_options_ptr automatic pointer dcl 3-15 mailbox_n_messages automatic fixed bin(17,0) dcl 1-32 msg_struct based structure level 1 unaligned dcl 5-22 msg_structp automatic pointer dcl 5-20 n_messages automatic fixed bin(17,0) dcl 5-3 nonexist_msgs based structure level 1 unaligned dcl 5-15 nonexist_msgsp automatic pointer dcl 5-13 open_options_ptr automatic pointer dcl 2-14 window_$bell 000000 constant entry external dcl 4-6 window_$change_column 000000 constant entry external dcl 4-63 window_$change_line 000000 constant entry external dcl 4-59 window_$clear_region 000000 constant entry external dcl 4-7 window_$clear_to_end_of_line 000000 constant entry external dcl 4-9 window_$clear_to_end_of_window 000000 constant entry external dcl 4-11 window_$create 000000 constant entry external dcl 4-72 window_$delete_chars 000000 constant entry external dcl 4-15 window_$destroy 000000 constant entry external dcl 4-74 window_$edit_line 000000 constant entry external dcl 4-76 window_$get_cursor_position 000000 constant entry external dcl 4-17 window_$get_echoed_chars 000000 constant entry external dcl 4-22 window_$get_one_unechoed 000000 constant entry external dcl 4-67 window_$get_one_unechoed_char 000000 constant entry external dcl 4-67 window_$get_unechoed_chars 000000 constant entry external dcl 4-25 window_$insert_text 000000 constant entry external dcl 4-28 window_$overwrite_text 000000 constant entry external dcl 4-29 window_$position_cursor 000000 constant entry external dcl 4-31 window_$position_cursor_rel 000000 constant entry external dcl 4-36 window_$scroll_region 000000 constant entry external dcl 4-42 window_$sync 000000 constant entry external dcl 4-44 window_$write_raw_text 000000 constant entry external dcl 4-48 window_$write_sync_read 000000 constant entry external dcl 4-53 xmail_version internal static varying char(10) initial dcl 6-84 NAMES DECLARED BY EXPLICIT CONTEXT. CURRENT_EXIT 001521 constant label dcl 264 ref 225 391 ORIG_AND_REPLY_EXIT 002203 constant label dcl 360 ref 332 SINGLE_EXIT 001726 constant label dcl 303 ref 289 backout_filed_msg 003331 constant entry internal dcl 472 ref 411 422 close_file 004010 constant entry internal dcl 533 ref 494 528 current_msgs 000771 constant entry external dcl 185 file_message 002204 constant entry internal dcl 366 ref 254 297 340 350 original_and_reply 001731 constant entry external dcl 307 print_filed_msg 003067 constant entry internal dcl 442 ref 260 432 save_message_count 003135 constant entry internal dcl 449 ref 240 single_msg 001526 constant entry external dcl 267 xmail_file_msgs_ 000723 constant entry external dcl 28 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 4546 4650 4113 4556 Length 5254 4113 102 370 433 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME xmail_file_msgs_ 582 external procedure is an external procedure. file_message internal procedure shares stack frame of external procedure xmail_file_msgs_. print_filed_msg internal procedure shares stack frame of external procedure xmail_file_msgs_. save_message_count internal procedure shares stack frame of external procedure xmail_file_msgs_. backout_filed_msg 154 internal procedure enables or reverts conditions. on unit on line 489 88 on unit close_file 118 internal procedure is called by several nonquick procedures. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME backout_filed_msg 000100 bfm_code backout_filed_msg 000102 bfm_mailbox_ptr backout_filed_msg 000104 bfm_message_ptr backout_filed_msg xmail_file_msgs_ 000100 add_more_msg xmail_file_msgs_ 000101 allow_selection xmail_file_msgs_ 000102 code xmail_file_msgs_ 000103 create_if_not_found xmail_file_msgs_ 000104 default_file xmail_file_msgs_ 000115 dir xmail_file_msgs_ 000167 file_mode xmail_file_msgs_ 000170 i xmail_file_msgs_ 000171 prefix xmail_file_msgs_ 000202 message_count xmail_file_msgs_ 000203 message_num xmail_file_msgs_ 000204 message_no_string xmail_file_msgs_ 000270 message_ptr xmail_file_msgs_ 000272 msg_filed_sw xmail_file_msgs_ 000273 needs_filing xmail_file_msgs_ 000274 original_message_count xmail_file_msgs_ 000275 prompt_string xmail_file_msgs_ 000376 unused_return_length xmail_file_msgs_ 000377 yes_sw xmail_file_msgs_ 000400 unused_bit xmail_file_msgs_ 000401 auto_open_options xmail_file_msgs_ 000406 auto_close_options xmail_file_msgs_ 000412 mailbox_ptr xmail_file_msgs_ 000414 curr_msgsp xmail_file_msgs_ 000446 smc_code save_message_count THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. r_g_a alloc_char_temp cat_realloc_chars call_ext_out_desc call_ext_out call_int_this call_int_other return_mac enable_op shorten_stack ext_entry int_entry THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. continue_to_signal_ ioa_ ioa_$rsnnl mail_system_$close_mailbox mail_system_$get_message_counts mail_system_$mark_message_for_deletion mail_system_$open_mailbox mail_system_$read_message mail_system_$save_message timer_manager_$sleep window_$clear_window xmail_error_$code_first xmail_error_$no_code xmail_get_str_$yes_no xmail_select_file_ xmail_validate_$curr_msgs xmail_validate_$mbx THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$badcall error_table_$noentry error_table_$rqover iox_$user_output mlsys_et_$mailbox_full mlsys_et_$no_a_permission mlsys_et_$no_r_permission mlsys_et_$no_savebox mlsys_et_$savebox_created xmail_data_ptr xmail_err_$no_curr_msgs xmail_err_$no_savebox LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 143 000716 28 000722 180 000731 185 000763 203 001004 204 001016 207 001052 210 001103 211 001114 216 001150 217 001154 218 001157 219 001165 220 001170 221 001172 223 001173 224 001175 225 001265 226 001270 228 001271 229 001300 230 001305 233 001307 234 001310 235 001311 240 001314 245 001317 246 001327 247 001332 249 001340 250 001353 253 001413 254 001420 255 001421 257 001453 258 001505 260 001510 262 001513 264 001521 267 001522 279 001541 280 001542 282 001543 283 001545 284 001551 285 001557 287 001562 288 001563 289 001653 290 001656 292 001657 293 001666 294 001673 297 001675 299 001676 301 001720 303 001726 307 001727 322 001744 324 001745 325 001746 326 001750 327 001754 328 001762 330 001765 331 001766 332 002056 333 002061 335 002062 336 002071 337 002076 340 002100 341 002101 343 002124 346 002140 347 002142 348 002146 350 002147 351 002150 353 002152 354 002172 355 002200 356 002201 360 002203 366 002204 369 002205 370 002207 371 002212 372 002253 374 002256 375 002257 376 002261 378 002262 380 002265 381 002314 382 002331 383 002337 387 002377 388 002430 389 002431 390 002432 391 002434 393 002435 395 002436 397 002440 398 002457 399 002461 400 002462 405 002463 407 002465 410 002522 411 002535 412 002541 414 002573 416 002574 418 002576 421 002637 422 002656 423 002662 425 002720 427 002721 431 002761 432 002764 433 002765 434 003032 435 003033 436 003064 438 003065 440 003066 442 003067 446 003070 447 003134 449 003135 458 003136 459 003137 461 003140 462 003221 464 003264 466 003270 468 003327 472 003330 484 003336 485 003351 486 003352 487 003354 489 003355 491 003371 493 003376 494 003411 496 003416 497 003426 501 003427 503 003441 504 003444 505 003447 506 003451 508 003453 509 003526 512 003570 513 003604 515 003612 516 003625 519 003666 520 003674 521 003705 523 003752 528 003755 529 003761 530 003774 531 004006 533 004007 538 004015 539 004021 540 004023 541 004025 543 004027 544 004044 546 004106 ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group BULL including BULL HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell BULL Inc., Groupe BULL and BULL HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, BULL or BULL HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by BULL HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved