COMPILATION LISTING OF SEGMENT rmdb_rq_free_db Compiled by: Multics PL/I Compiler, Release 29, of July 28, 1986 Compiled at: Honeywell Multics Op. - System M Compiled on: 10/16/86 1337.2 mst Thu Options: optimize map 1 /****^ *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Information Systems Inc., 1982 * 4* * * 5* *********************************************************** */ 6 7 rmdb_rq_free_db: proc (sci_ptr, info_ptr); 8 9 10 /****^ HISTORY COMMENTS: 11* 1) change(85-12-04,Spitzer), approve(85-12-04,MCR7311), 12* audit(86-09-02,Blair), install(86-10-16,MR12.0-1187): 13* If we have a xreference file, destroy it. Terminate the model properly. 14* END HISTORY COMMENTS */ 15 16 17 /* 18* . BEGIN_DESCRIPTION 19* This routine implements the relesae_db request within the 20* restructure_mrds_db subsystem. It checks to be sure that the 21* request has been called with 0 arguments and that a database has 22* already been readied so that it makes sense to try to release it. 23* . END_DESCRIPTION 24* 25* Known Bugs: 26* 27* Other Problems: 28* 29* 30* 31* 32* 33* 34* . HISTORY 35* 82-03-29 Davids: Written 36* 37* 82-05-25 Davids: modified to set rmdb_ctl.db_model_ptr to null at 38* . the same time that the absolute_db_path is set 39* . to "". 40* 41* 83-05-24 Davids: Changed the argument list to rmdb_free_db to include 42* a pointer to the saved_res_version. 43**/ 44 45 /* PARAMETERS */ 46 dcl sci_ptr ptr; /* (input) pointer to the subsystem control info structure */ 47 /* need to be able to pass it to the ssu routines */ 48 dcl info_ptr ptr; /* (input) pointer to the rmdb_ctl structure which is both */ 49 /* read and written. */ 50 51 /* EXTERNAL STATIC */ 52 53 dcl error_table_$action_not_performed fixed bin (35) external static; 54 dcl error_table_$badcall fixed bin (35) external static; 55 56 /* ENTRIES */ 57 58 dcl mdbm_util_$xref_destroy entry (ptr, char(*), char(*), char(*), fixed bin(35)); 59 dcl rmdb_free_db entry (char (168), ptr, char (500), fixed bin (35)); 60 dcl ssu_$abort_line entry options (variable); 61 dcl ssu_$arg_count entry (ptr, fixed bin); 62 dcl terminate_file_ entry (ptr, fixed bin(24), bit(*), fixed bin(35)); 63 64 /* INTERNAL AUTOMATIC */ 65 66 dcl code fixed bin (35); /* standard error code */ 67 dcl error_message char (500); /* error message returned from rmdb_free_db */ 68 dcl nargs fixed bin; /* number of arguments the request was called with */ 69 70 /* BUILTINS */ 71 72 dcl null builtin; 73 74 /* INCLUDES */ 75 1 1 /* BEGIN - mrds_rmdb_ctl.incl.pl1 */ 1 2 1 3 1 4 1 5 /****^ HISTORY COMMENTS: 1 6* 1) change(82-03-26,Davids), approve(), audit(), install(): 1 7* created 1 8* 2) change(82-05-26,Davids), approve(), audit(), install(): 1 9* added db_model_ptr 1 10* 3) change(82-06-09,Harvey), approve(), audit(), install(): 1 11* deleted ssu_ routines ptr storage 1 12* 4) change(82-08-20,Davids), approve(), audit(), install(): 1 13* added the relmgr like reference and included the rmdb_relmgr_entries 1 14* include file 1 15* 5) change(83-05-24,Davids), approve(), audit(), install(): 1 16* added the saved_res_version_ptr element 1 17* 6) change(84-10-23,Benjamin), approve(), audit(), install(): 1 18* added flags (just database_readied_by_rmdb for now). 1 19* 7) change(85-11-08,Spitzer), approve(85-11-08,MCR7311), 1 20* audit(86-09-02,Blair), install(86-10-16,MR12.0-1187): 1 21* added crossref_file_info. 1 22* END HISTORY COMMENTS */ 1 23 1 24 1 25 dcl 01 rmdb_ctl based (rmdb_ctl_ptr), 1 26 02 version fixed bin, 1 27 02 rmdb_version char (16) varying, 1 28 02 absolute_db_path char (168), 1 29 02 temp_dir_path char (168), 1 30 02 work_area_ptr ptr, 1 31 02 db_model_ptr ptr, 1 32 02 saved_res_version_ptr ptr, 1 33 02 crossref_file_info, 1 34 03 iocb_ptr ptr, 1 35 03 name char (32), 1 36 02 relmgr_entries like rmdb_relmgr_entries, 1 37 02 flags, 1 38 03 database_readied_by_rmdb bit (1) unal, 1 39 03 unused bit (35) unal; 1 40 1 41 dcl RMDB_CTL_VERSION_1 fixed bin init (1) internal static options (constant); 1 42 1 43 dcl rmdb_ctl_ptr ptr; 1 44 1 45 2 1 /* START OF: rmdb_relmgr_entries.incl.pl1 * * * * * * * * * * * * * * * * */ 2 2 2 3 2 4 /****^ HISTORY COMMENTS: 2 5* 1) change(82-08-20,Davids), approve(), audit(), install(): 2 6* written 2 7* 2) change(86-01-28,Spitzer), approve(86-01-28,MCR7311), 2 8* audit(86-09-15,Gilcrease), install(86-10-16,MR12.0-1187): 2 9* add get_tuples_by_spec, put_tuple, put_tuples, create_cursor entry points. 2 10* 3) change(86-08-21,Blair), approve(86-08-21,MCR7311), 2 11* audit(86-09-15,Gilcrease), install(86-10-16,MR12.0-1187): 2 12* Back out the entries get_tuples_by_spec and put_tuples since they aren't 2 13* sufficiently well tested to be reliable. Replace with get_tuple_id and 2 14* get_tuple_by_id. 2 15* END HISTORY COMMENTS */ 2 16 2 17 2 18 dcl 01 rmdb_relmgr_entries based (rmdb_relmgr_entries_ptr), 2 19 02 create_relation entry (char (*), char (*), ptr, ptr, bit (36) aligned, 2 20 bit (36) aligned, fixed bin (35)), 2 21 02 delete_relation entry (char (*), char (*), fixed bin (35)), 2 22 02 open entry (char (*), char (*), bit (36) aligned, fixed bin (35)), 2 23 02 close entry (bit (36) aligned, fixed bin (35)), 2 24 02 create_index entry (bit (36) aligned, ptr, bit (36) aligned, fixed bin (17), 2 25 bit (36) aligned, fixed bin (35)), 2 26 02 delete_index entry (bit (36) aligned, bit (36) aligned, fixed bin (35)), 2 27 02 put_tuple entry (ptr, ptr, bit (36) aligned, fixed bin (35)), 2 28 02 get_tuple_id entry (ptr, ptr, ptr, ptr, fixed bin (35)), 2 29 02 get_tuple_by_id entry (ptr, bit (36) aligned, ptr, ptr, ptr, fixed bin (35)), 2 30 02 create_cursor entry (bit (36) aligned, ptr, ptr, fixed bin (35)); 2 31 2 32 dcl rmdb_relmgr_entries_ptr ptr; 2 33 2 34 /* END OF: rmdb_relmgr_entries.incl.pl1 * * * * * * * * * * * * * * * * */ 1 46 1 47 1 48 1 49 /* END - mrds_rmdb_ctl.incl.pl1 */ 76 3 1 /* BEGIN INCLUDE FILE ... terminate_file.incl.pl1 */ 3 2 /* format: style2,^inddcls,idind32 */ 3 3 3 4 declare 1 terminate_file_switches based, 3 5 2 truncate bit (1) unaligned, 3 6 2 set_bc bit (1) unaligned, 3 7 2 terminate bit (1) unaligned, 3 8 2 force_write bit (1) unaligned, 3 9 2 delete bit (1) unaligned; 3 10 3 11 declare TERM_FILE_TRUNC bit (1) internal static options (constant) initial ("1"b); 3 12 declare TERM_FILE_BC bit (2) internal static options (constant) initial ("01"b); 3 13 declare TERM_FILE_TRUNC_BC bit (2) internal static options (constant) initial ("11"b); 3 14 declare TERM_FILE_TERM bit (3) internal static options (constant) initial ("001"b); 3 15 declare TERM_FILE_TRUNC_BC_TERM bit (3) internal static options (constant) initial ("111"b); 3 16 declare TERM_FILE_FORCE_WRITE bit (4) internal static options (constant) initial ("0001"b); 3 17 declare TERM_FILE_DELETE bit (5) internal static options (constant) initial ("00001"b); 3 18 3 19 /* END INCLUDE FILE ... terminate_file.incl.pl1 */ 77 78 79 /* 80* Init the value of the rmdb_ctl pointer 81**/ 82 83 rmdb_ctl_ptr = info_ptr; 84 85 86 87 88 89 /* 90* Get the number of arguments that the request was called with - if 91* its not 0 its an error. 92* 93* Note that ssu_$abort_line does not return. 94**/ 95 96 call ssu_$arg_count (sci_ptr, nargs); 97 if nargs ^= 0 98 then call ssu_$abort_line (sci_ptr, error_table_$badcall, 99 "^/The free_db (fdb) request is called without any arguments"); 100 101 102 103 104 105 /* 106* If the absolute_db_path element of the rmdb_ctl structure is null 107* it means that no database is currently readied - this is an 108* error. 109**/ 110 111 if rmdb_ctl.absolute_db_path = "" 112 then call ssu_$abort_line (sci_ptr, error_table_$action_not_performed, 113 "^/There is no currently readied database to be freed"); 114 115 /* 116* the only errors that are now possible will occur within the call 117* to rmdb_free_db. 118**/ 119 120 call rmdb_free_db (rmdb_ctl.absolute_db_path, rmdb_ctl.saved_res_version_ptr, error_message, code); 121 if code ^= 0 122 then call ssu_$abort_line (sci_ptr, code, error_message); 123 124 125 /* 126* Get rid of the xreference file. 127**/ 128 129 if rmdb_ctl.crossref_file_info.iocb_ptr ^= null 130 then call mdbm_util_$xref_destroy (rmdb_ctl.crossref_file_info.iocb_ptr, rmdb_ctl.temp_dir_path, 131 rmdb_ctl.crossref_file_info.name, (""), (0)); 132 133 134 /* 135* By changing rmdb_ctl.absolute_db_path to "" we indicate that 136* there is no currently readied db. 137**/ 138 139 rmdb_ctl.absolute_db_path = ""; 140 141 if rmdb_ctl.db_model_ptr ^= null 142 then call terminate_file_ (rmdb_ctl.db_model_ptr, 0, TERM_FILE_TERM, (0)); 143 144 return; 145 146 end rmdb_rq_free_db; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 10/16/86 1143.3 rmdb_rq_free_db.pl1 >special_ldd>install>MR12.0-1187>rmdb_rq_free_db.pl1 76 1 10/16/86 1139.6 mrds_rmdb_ctl.incl.pl1 >special_ldd>install>MR12.0-1187>mrds_rmdb_ctl.incl.pl1 1-46 2 10/16/86 1140.2 rmdb_relmgr_entries.incl.pl1 >special_ldd>install>MR12.0-1187>rmdb_relmgr_entries.incl.pl1 77 3 04/06/83 1239.4 terminate_file.incl.pl1 >ldd>include>terminate_file.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. TERM_FILE_TERM 000000 constant bit(3) initial unaligned dcl 3-14 set ref 141* absolute_db_path 6 based char(168) level 2 packed unaligned dcl 1-25 set ref 111 120* 139* code 000100 automatic fixed bin(35,0) dcl 66 set ref 120* 121 121* crossref_file_info 140 based structure level 2 unaligned dcl 1-25 db_model_ptr 134 based pointer level 2 dcl 1-25 set ref 141 141* error_message 000101 automatic char(500) unaligned dcl 67 set ref 120* 121* error_table_$action_not_performed 000010 external static fixed bin(35,0) dcl 53 set ref 111* error_table_$badcall 000012 external static fixed bin(35,0) dcl 54 set ref 97* info_ptr parameter pointer dcl 48 ref 7 83 iocb_ptr 140 based pointer level 3 dcl 1-25 set ref 129 129* mdbm_util_$xref_destroy 000014 constant entry external dcl 58 ref 129 name 142 based char(32) level 3 packed unaligned dcl 1-25 set ref 129* nargs 000276 automatic fixed bin(17,0) dcl 68 set ref 96* 97 null builtin function dcl 72 ref 129 141 rmdb_ctl based structure level 1 unaligned dcl 1-25 rmdb_ctl_ptr 000300 automatic pointer dcl 1-43 set ref 83* 111 120 120 129 129 129 129 139 141 141 rmdb_free_db 000016 constant entry external dcl 59 ref 120 rmdb_relmgr_entries based structure level 1 unaligned dcl 2-18 saved_res_version_ptr 136 based pointer level 2 dcl 1-25 set ref 120* sci_ptr parameter pointer dcl 46 set ref 7 96* 97* 111* 121* ssu_$abort_line 000020 constant entry external dcl 60 ref 97 111 121 ssu_$arg_count 000022 constant entry external dcl 61 ref 96 temp_dir_path 60 based char(168) level 2 packed unaligned dcl 1-25 set ref 129* terminate_file_ 000024 constant entry external dcl 62 ref 141 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. RMDB_CTL_VERSION_1 internal static fixed bin(17,0) initial dcl 1-41 TERM_FILE_BC internal static bit(2) initial unaligned dcl 3-12 TERM_FILE_DELETE internal static bit(5) initial unaligned dcl 3-17 TERM_FILE_FORCE_WRITE internal static bit(4) initial unaligned dcl 3-16 TERM_FILE_TRUNC internal static bit(1) initial unaligned dcl 3-11 TERM_FILE_TRUNC_BC internal static bit(2) initial unaligned dcl 3-13 TERM_FILE_TRUNC_BC_TERM internal static bit(3) initial unaligned dcl 3-15 rmdb_relmgr_entries_ptr automatic pointer dcl 2-32 terminate_file_switches based structure level 1 packed unaligned dcl 3-4 NAME DECLARED BY EXPLICIT CONTEXT. rmdb_rq_free_db 000056 constant entry external dcl 7 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 436 464 321 446 Length 726 321 26 226 115 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME rmdb_rq_free_db 254 external procedure is an external procedure. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME rmdb_rq_free_db 000100 code rmdb_rq_free_db 000101 error_message rmdb_rq_free_db 000276 nargs rmdb_rq_free_db 000300 rmdb_ctl_ptr rmdb_rq_free_db THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. call_ext_out_desc call_ext_out return_mac ext_entry THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. mdbm_util_$xref_destroy rmdb_free_db ssu_$abort_line ssu_$arg_count terminate_file_ THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$action_not_performed error_table_$badcall LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 7 000052 83 000063 96 000067 97 000077 111 000126 120 000160 121 000176 129 000222 139 000261 141 000265 144 000320 ----------------------------------------------------------- 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