COMPILATION LISTING OF SEGMENT create_mrds_dsm Compiled by: Multics PL/I Compiler, Release 29, of July 28, 1986 Compiled at: Honeywell Multics Op. - System M Compiled on: 08/15/86 1450.2 mst Fri Options: optimize map 1 /****^ *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Information Systems Inc., 1981 * 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-06-09,Dupuis), approve(86-08-05,MCR7491), audit(86-08-08,Blair), 14* install(86-08-15,MR12.0-1127): 15* There were several inconsistencies and problems with its usage message 16* (mrds #149, phx19350). Changed the code so that each call to com_err_ used 17* a constant for the usage message. 18* END HISTORY COMMENTS */ 19 20 21 create_mrds_dsm: cmdsm: proc; 22 23 /* 24* Create a MRDS database submodel (dsm) from a cmdsm source. Most 25* of the interesting code is in four subroutines: 26* . mrds_dsm_parse, 27* . mrds_dsm_scanner, 28* . mrds_dsm_semantics, and 29* . mrds_dsm_compute_access. 30* To change either the syntax or semantics involved in the creation 31* of a dsm, the LRK source, mrds_dsm_parse.lrk, must be edited, 32* followed by a series of include file generations and program 33* recompilations. This is all automated in an exec_com, 34* compile_dsm_lrk.ec . 35* 36* . lrk mrds_dsm_parse -ssl 37* . 38* . ted$com >udd>LIS>Wardd>lrk|hal_dcl mrds_dsm_parse mrds_dsm_terminals 39* . ted$com >udd>LIS>Wardd>Wardd|incl_cmt mrds_dsm_terminals 40* . indent mrds_dsm_terminals.incl 41* . 42* . >udd>LIS>Wardd>msd mrds_dsm_parse mrds_dsm_skip_table 43* . ted$com >udd>LIS>Wardd>Wardd|incl_cmt mrds_dsm_skip_table 44* . indent mrds_dsm_skip_table.incl 45* . indent mrds_dsm_semantics 46* . 47* . pl1 mrds_dsm_parse -tb -map 48* . pl1 mrds_dsm_semantics -tb -map 49* . pl1 mrds_dsm_scanner -tb -map 50* 51* Known Bugs: 52* 53* Other Problems: 54* 55* The submodel file is used as a scratch pad to store access 56* records and model relation names. This information is never 57* cleaned up. It should at least be removed from the submodel when 58* its finished and should probably be moved to some other file. 59* 60* HISTORY: 61* 62* 80-02-01 Spratt: written 63* 64* 80-06-24 Spratt: Put working submodel in the process_dir using 65* . mrds_dsm_define_temp, added submodel validation via 66* . mrds_dsm_valid_. 67* 68* 80-10-29 Spratt: Added deletion of the temporary submodel in the 69* . finish proc, under the control of a new switch, 70* . control_debug_submodel. Added a new control argument, 71* . "-debug_submodel", to set the control_debug_submodel 72* . switch. 73* 74* 80-11-08 Spratt: Added the -install control argument. submodels 75* . are now stored in the users working directory unless the 76* . -install control argument is given, in which case it is 77* . "installed" under the database submodel directory. A 78* . call to a new dsm subroutine mrd_dsm_set_db_path was 79* . added to set the database pathname in the submodel 80* . header. Append access on the database directory is now 81* . only checked for when installing. 82* 83* 11/25/80 by Lindsey Spratt: Changed "finish" processing. The 84* . finish procedure now takes an argument which tells it to 85* . delete the submodel. Most calls to finish now use a 86* . variable as the argument, submodel_deletion_control. 87* . Before the dsm has been created, or defined, by the 88* . current invocation of cmdsm, submodel_deletion_control 89* . is set to DONT_DELETE_SUBMODEL. Once cmdsm has 90* . successfully defined the submodel 91* . submodel_deletion_control is set to DELETE_SUBMODEL. 92* . Name duplication handling has been added for the 93* . submodel. If a dsm of the given name already exists, 94* . nd_handler_ is called. The access on the database now 95* . checked for is sma, instead of a. If the 96* . secure.submodels directory doesn't already exist (and 97* . cmdsm was invoked with -install), it is created. All of 98* . the error messages are now preceded by a newline. The 99* . submodel is now created in place, instead of copied from 100* . the process_dir. mrds_dsm_define_temp was changed to use 101* . the dsm_path argument as an input argument if it was 102* . non-null. Mrds_dsm_dmdsm is now called if validate is 103* . on, even if generate_display is off. This is to use the 104* . validation aspect of mrds_dsm_dmdsm. Iocbs are now 105* . destroyed after being closed. 106* 107* 81-01-12 Davids: changed the references of mrds_dsm_display_rels 108* . to mrds_dsm_relation_names, changed the area set up from 109* . zero_on_free to zero_on_alloc and removed the call to 110* . emtry which came right after the call to define_area_ 111* 112* 81-01-22 Davids: changed mrds_dsm_open_read to 113* . mrds_dsm_open$read. 114* 115* 81-01-28 Davids: removed the mrds_dsm_relation_names include file 116* . which was used. 117* 118* 81-02-10 Davids: reformated the header and declaration sections 119* 120* . reformated the code so that the argument processing, 121* . model path processing and submodel path processing are 122* . on separate pages. 123* 124* . removed calls to the internal procedure finish which 125* . were not needed, nothing that finish cleans up was yet 126* . allocated. 127* 128* . rewrote the argument processing so that it is much 129* . simpler and only takes the control arguments -list, -ls, 130* . -^list, -^ls, -install, -ins, -^install, -^ins. also the 131* . first non-control argument is the cmdsm source, the next 132* . is the db path, control args may come before, between, 133* . or after the path arguments. 134* 135* 81-02-17 Davids: changed the arguments ^list, ^ls, ^install, and 136* . ^ins to no_list, nls, no_install and nins. 137* 138* . move the processing of the list path so that it is the 139* . first thing done, also if the list segment already 140* . exists it is truncated, if it does not exist it is 141* . created. if an error occurs before usefull information 142* . is placed in the listing and the listing was created it 143* . is deleted. 144* 145* . changed the name of the variable controling submodel 146* . deletion from submodel_deletion_control to 147* . delete_submodel. Also changed the finish procedure to 148* . use the gobal variables delete_submodel and 149* . delete_listing rather than have parameters. 150* 151* 81-02-18 Davids: fixed a bunch of errors that were introduced 152* . when the listing segment processing was moved. these 153* . included using elements of structures that were not 154* . allocated, pointers that were not null'ed and typos that 155* . were also variables. also changed the finish procedure 156* . so that it does not use the pointers in the 157* . mrds_dsm_parse_info str but uses the automatic pointers 158* . that are used to set the pointer elements in 159* . mrds_dsm_parse_info. 160* 161* . replaced get/release_temp_segments_ with 162* . get/release_temp_segment. only one temp segment is ever 163* . used. 164* 165* . changed the name of the submodel_name variable to 166* . dsm_name so that the variable names refering to the 167* . submodel segment are more consistant. 168* 169* . changed all calls to mrds_dsm_close in the finsh 170* . procedure to mrds_dsm_close$force. also removed the call 171* . to iox_$destroy_iocb since that is now done by close. 172* 173* . changed the name of source_dir to cmdsm_source_dir, 174* . source_entry to cmdsm_source_entry and delete_submodel 175* . to delete_dsm for more consistant names. 176* 177* 81-02-19 Davids: added security and DBAness checks. now only a 178* . DBA can use the -install (-ins) control argument, if a 179* . DBA creates a submodel for a secure database and does 180* . not install it a warning message is issued and only a 181* . DBA can use the cmdsm command against a secure database. 182* 183* . changed the error message for a non-existant cmdsm 184* . source. 185* 186* 81-02-25 Davids header and declaration sections reformated. 187* . removed the include files iox_modes, iox_dcls, 188* . mrds_dsm_entry_dcls, and control_argument_dcls. 189* 190* . changed the call to dmd_$open_dm to mrds_dm_open$open_dm 191* . so secure databases can be opened. 192* 193* . access of sma is now put on the submodel directory (for 194* . the DBA) if the install option is used and access was 195* . not already there. 196* 197* . mrds_dsm_dmdsm is now called only if a listing is to be 198* . preoduced. it is called in such a manner that validation 199* . is not done. submodel validation will be done by 200* . semantics and compute_access. 201* 202* . the call to mrds_dsm_set_db_path was replaced with 203* . mrds_dsm_write_header which will write a complete 204* . header, i.e. set the relation count. 205* 206* 81-02-26 Davids: changed the call of mrds_dm_open$open_dm to just 207* . mrds_dm_open. 208* 209* 81-02-27 Davids removed the iox_$user_output declaration. this 210* . pointer was used if a listing was not going to be 211* . generated but the call to mrds_dsm_dmdsm was done to 212* . validate the submodel. the call is now made only to 213* . produce a listing. 214* 215* . changed the call to dmd_$close_dm to mrds_dm_close. 216* 217* . mrds_dsm_dmdsm always expects the validate bit in 218* . dsm_display_info to be set. if it is not set dmdsm blows 219* . up with a null pointer. The bit is now set. 220* 221* 81-03-02 Davids: changed error_table_$arg_err to argerr. arg_err 222* . does not exist. 223* 224* 81-05-05 Davids: added force and no_force control arguments 225* 226* . now using hcs_status_ rather than hcs_$get_user_effmode 227* . to determine the acl on the secure.submodels directory. 228* 229* . now calling mrds_dm_authorization$set_needed_access 230* . rather than hcs_$add_dir_acl to set the acl on the 231* . secure.submodels directory for a DBA 232* 233* . changed name duplication handling to only delete a 234* . segment (msf) if its a submodel and to only unlink a 235* . link if its target is a submodel. 236* 237* 81-05-07 Davids: modified to set the value of 238* . mrds_dsm_parse_info.data_mode_ptr, which was just added 239* . to the mrds-dsm_parse_info structure. 240* 241* 81-05-11 Davids: changed the calling sequence of 242* . mrds_dsm_compute_access to include the pointer to the 243* . listing iocb. 244* 245* 81-05-13 Davids: added code to call cmdsm_v1 in the event that 246* . the database is a version 3 or earlier. reordered the 247* . processing of db_path and listing so that the db_path is 248* . first, followed by the submodel path, followed by the 249* . listing path. 250* 251* 81-05-15 Davids: modified to check the 252* . mrds_dsm_parse_info.highest_severity* values and to 253* . delete the created submodel unless all values are zero. 254* . Also the listing will not contain the dmdsm display if 255* . the source had errors. 256* 257* 81-05-22 Davids: added data_model_ptr to the parameters of 258* . mrds_dsm_compute_access so that it can determine if the 259* . relation access is valid. 260* 261* 81-05-27 Davids: changed the setting of delete_dsm so that it is 262* . inited to "1"b and so that it is only set to "0"b if no 263* . errors occured. There used to be a window where the only 264* . thing in the submodel would be the header record. 265* 266* 81-05-28 Davids: modified to handle the new mrds_dsm_display_info 267* . structure (replaces the dsm_display_info structure). 268* 269* . modified so that if the responce from nd_handler is no 270* . the old submodel is not deleted, this started happening 271* . when the default value of delete_dsm was set to "1"b 272* . instead of "0"b. 273* 274* 81-05-29 Davids: modified so that if an entry with the submodel 275* . name already exists and its not a submodel it is not 276* . deleted and so that as long asa non-zero error code is 277* . return from nd_handler the entry is not deleted. 278* 279* 81-06-25 Davids: Changed the references to 280* . mrds_dsm_parse_info.submodel_iocb_ptr in the calls to 281* . write_header and close to references to dsm_iocb_ptr. 282* . both pointers start off withthe same value but the call 283* . to close changes the value to null - a new version of 284* . iox_ does this now (it didn't use to). the new version 285* . of iox_ also goes crazy when you give it a pointer to an 286* . iocb that it has already close/detached/destroyed. this 287* . change gets around the changed behavior of iox. 288* 289* 81-07-21 Jim Gray : changed logic to not try to build a submodel, 290* if a severity >= 1 occured in the parsing. Also added message 291* about submodel not being created, and the highest severity error 292* message seen, if the severity was > 0. 293* 294* 81-08-06 Davids: changed the inited value of delete_dsm to "0"b 295* . (from "1"b) and do not set it to "1"b until the submodel 296* . msf has been successfully created i.e. after the call 297* . the mrds_dsm_define_temp and its associated error and 298* . name_dup processing. This elimintaed several setting of 299* . the switch to "0"b before this point. This change is 300* . required because if an error occurs before the value of 301* . dsm_name is set (in the call to hcs_$initiate_count) it 302* . could be "" or garbadge, if its null then the finish 303* . procedure will end up deleting the working directory. 304* 305* 83-06-21 Davids: Removed check for old version database and the call 306* to v1 code if it was an old version db (old version dbs can no longer 307* be opened) 308**/ 309 310 /* AUTOMATIC */ 311 312 dcl arg_index fixed bin; /* index of argument */ 313 dcl arg_len fixed bin (21); /* length of argument */ 314 dcl arg_ptr ptr; /* pointer to argument */ 315 316 dcl cmdsm_source_bc fixed bin (24); /* bit count of the cmdsm source */ 317 dcl cmdsm_source_dir char (168); /* directory containing cmdsm source */ 318 dcl cmdsm_source_entry char (32); /* entry name of cmdsm source */ 319 dcl cmdsm_source_path char (168); /* path of cmdsm source */ 320 dcl cmdsm_source_ptr ptr init (null ());/* pointer to the cmdsm source */ 321 322 dcl code fixed bin (35); /* error code */ 323 324 dcl control_debug_parse bit (1) init ("0"b); /* debug switch for mrds_dsm_parse */ 325 dcl control_debug_scanner bit (1) init ("0"b); /* debug switch for mrds_dsm_scanner */ 326 dcl control_debug_semantics bit (1) init ("0"b); /* debug switch for mrds_dsm_semantics */ 327 328 dcl data_model_ptr ptr init (null ());/* pointer to the database data_model segment */ 329 330 dcl db_path char (168) init (""); /* path of database directory */ 331 332 dcl delete_dsm bit (1) init ("0"b); /* controls deletion of submodel msf */ 333 dcl delete_listing bit (1) init ("0"b); /* controls deletion of listing segment */ 334 335 dcl dsm_dir char (168); /* containing directory of submodel */ 336 dcl dsm_iocb_ptr ptr init (null ());/* iocb pointer to the submodel */ 337 dcl dsm_name char (32); /* entry name of submodel msf */ 338 dcl dsm_path char (168); /* path of submodel */ 339 340 dcl force bit (1) unal init ("0"b); /* true if existing submodel should be deleted without query */ 341 dcl install bit (1) init ("0"b); /* true if submodel is to be installed */ 342 343 dcl listing_dir char (168) init (""); /* directory containing the listing segment */ 344 dcl listing_entry char (32) init (""); /* entry name of listing segment */ 345 dcl listing_iocb_ptr ptr init (null ());/* iocb pointer to the listing segment */ 346 dcl listing_ptr ptr init (null ());/* pointer to the listing segment */ 347 348 dcl local_area area (1000); /* local area for allocs, no need to free */ 349 declare max_severity fixed bin; /* highest severity error seen */ 350 dcl nargs fixed bin; /* number of arguments this command was called with */ 351 dcl produce_listing bit (1) aligned init ("0"b); /* true if listing is to be produced */ 352 353 dcl ring fixed bin; /* user ring */ 354 dcl ring_array (3) fixed bin (3); /* ring brackets for submodel dir */ 355 356 dcl 01 status_stuff like status_branch;/* space for status to put info in */ 357 358 dcl temp_dsm_path char (168) init (""); /* path to a temp segment used as a local area */ 359 dcl temp_seg_ptr ptr init (null ());/* pointer to the temp segment */ 360 361 dcl user_id char (32); /* person.project.tag of user */ 362 dcl work_area_ptr ptr init (null ());/* pointer to the local area */ 363 364 /* BASED */ 365 366 dcl arg char (arg_len) based (arg_ptr); /* the argument */ 367 dcl work_area area (sys_info$max_seg_size) based (work_area_ptr); 368 369 /* BUILTIN */ 370 371 dcl addr builtin; 372 dcl divide builtin; 373 dcl empty builtin; 374 dcl fixed builtin; 375 dcl length builtin; 376 dcl max builtin; 377 dcl null builtin; 378 dcl rtrim builtin; 379 dcl substr builtin; 380 dcl unspec builtin; 381 382 /* CONDITION */ 383 384 dcl cleanup condition; 385 386 /* CONSTANT */ 387 388 dcl CMDSM_SUFFIX char (5) internal static options (constant) init ("cmdsm"); 389 dcl CREATE_A_DIRECTORY init (1) fixed bin (1) internal static options (constant); 390 dcl DONT_CHASE_LINKS init (0) fixed bin (1) internal static options (constant); 391 dcl DONT_COPY init (0) fixed bin (1) internal static options (constant); 392 dcl DSM_SUFFIX char (3) internal static options (constant) init ("dsm"); 393 dcl LISTING_SUFFIX char (4) internal static options (constant) init ("list"); 394 dcl MYNAME char (15) init ("create_mrds_dsm") internal static options (constant); 395 dcl SMA_MODE_VALUE init ("01011"b) bit (5) unal internal static options (constant); 396 dcl STREAM_OUTPUT fixed bin init (2) internal static options (constant); 397 dcl USAGE char (60) internal static options (constant) init 398 ("^/Usage: cmdsm dsm_source_path database_path {-control_args}"); 399 /* ENTRY */ 400 401 dcl absolute_pathname_ entry (char (*), char (*), fixed bin (35)); 402 dcl com_err_ entry options (variable); 403 dcl cu_$arg_count entry (fixed bin); 404 dcl cu_$arg_ptr entry (fixed bin, ptr, fixed bin (21), fixed bin (35)); 405 dcl define_area_ entry (ptr, fixed bin (35)); 406 dcl expand_pathname_ entry (char (*), char (*), char (*), fixed bin (35)); 407 dcl expand_pathname_$add_suffix entry (char (*), char (*), char (*), char (*), fixed bin (35)); 408 dcl get_group_id_$tag_star entry returns (char (32)); 409 dcl get_ring_ entry returns (fixed bin (3)); 410 dcl get_temp_segment_ entry (char (*), pointer, fixed bin (35)); 411 dcl get_wdir_ entry () returns (char (168)); 412 dcl hcs_$append_branchx entry (char (*), char (*), fixed bin (5), (3) fixed bin (3), char (*), 413 fixed bin (1), fixed bin (1), fixed bin (24), fixed bin (35)); 414 dcl hcs_$del_dir_tree entry (char (*), char (*), fixed bin (35)); 415 dcl hcs_$delentry_file entry (char (*), char (*), fixed bin (35)); 416 dcl hcs_$initiate entry (char (*), char (*), char (*), fixed bin (1), fixed bin (2), ptr, fixed bin (35)); 417 dcl hcs_$initiate_count entry (char (*), char (*), char (*), fixed bin (24), fixed bin (2), ptr, fixed bin (35)); 418 dcl hcs_$make_seg entry (char (*), char (*), char (*), fixed bin (5), ptr, fixed bin (35)); 419 dcl hcs_$status_ entry (char (*), char (*), fixed bin (1), ptr, ptr, fixed bin (35)); 420 dcl hcs_$terminate_noname entry (ptr, fixed bin (35)); 421 dcl hcs_$truncate_seg entry (ptr, fixed bin, fixed bin (35)); 422 dcl ioa_ options (variable) entry; 423 declare ioa_$ioa_switch entry options (variable); 424 dcl iox_$attach_name entry (char (*), ptr, char (*), ptr, fixed bin (35)); 425 dcl iox_$close entry (ptr, fixed bin (35)); 426 dcl iox_$destroy_iocb entry (ptr, fixed bin (35)); 427 dcl iox_$detach_iocb entry (ptr, fixed bin (35)); 428 dcl iox_$open entry (ptr, fixed bin, bit (1) aligned, fixed bin (35)); 429 dcl mrds_dm_authorization$get_user_class entry (char (*), ptr, fixed bin, ptr, fixed bin (35)); 430 dcl mrds_dm_authorization$set_needed_access entry (char (*), fixed bin (35)); 431 dcl mrds_dm_db_secured$get_secured_status entry (ptr, ptr, fixed bin, ptr, fixed bin (35)); 432 dcl mrds_dm_close entry (ptr, fixed bin (35)); 433 dcl mrds_dm_open entry (char (168), fixed bin, ptr, fixed bin (35)); 434 dcl mrds_dsl_get_version$get_path_info entry (char (*), ptr, fixed bin, ptr, fixed bin (35)); 435 dcl mrds_dsm_close entry (ptr, fixed bin (35)); 436 dcl mrds_dsm_close$force entry (ptr); 437 dcl mrds_dsm_compute_access entry (char (*), char (*), ptr, ptr, fixed bin (35)); 438 dcl mrds_dsm_define_temp entry (char (*), ptr, fixed bin (35)); 439 dcl mrds_dsm_dmdsm entry (ptr, fixed bin (35)); 440 dcl mrds_dsm_open$read entry (char (*), ptr, fixed bin (35)); 441 dcl mrds_dsm_parse entry (ptr, fixed bin (35)); 442 dcl mrds_dsm_write_header entry (ptr, char (*), fixed bin (35)); 443 dcl nd_handler_ entry (char (*), char (*), char (*), fixed bin (35)); 444 dcl nd_handler_$force entry (char (*), char (*), char (*), fixed bin (35)); 445 dcl pathname_ entry (char (*), char (*)) returns (char (168)); 446 dcl release_temp_segment_ entry (char (*), pointer, fixed bin (35)); 447 dcl suffixed_name_$new_suffix entry (char (*), char (*), char (*), char (32), fixed bin (35)); 448 449 /* EXTERNAL */ 450 451 dcl error_table_$action_not_performed fixed bin (35) external static; 452 dcl error_table_$bad_arg fixed bin (35) external static; 453 dcl error_table_$empty_file fixed bin (35) external static; 454 dcl error_table_$insufficient_access fixed bin (35) external static; 455 dcl error_table_$namedup fixed bin (35) external static; 456 dcl error_table_$no_dir fixed bin (35) external static; 457 dcl error_table_$noentry fixed bin (35) external static; 458 dcl error_table_$pathlong fixed bin (35) external static; 459 dcl error_table_$wrong_no_of_args fixed bin (35) external static; 460 dcl iox_$error_output ptr external static; 461 dcl mrds_data_$dsmd_version_number fixed bin (35) external static; 462 dcl mrds_data_$submodel_dir_name char (16) external static; 463 dcl mrds_error_$no_database fixed bin (35) external static; 464 dcl mrds_error_$no_model_submodel fixed bin (35) external static; 465 dcl mrds_error_$version_3_db fixed bin (35) external static; 466 dcl sys_info$max_seg_size fixed bin (35) external static; 467 468 /* set up */ 469 470 on cleanup call finish; 471 472 call ioa_ ("CMDSM Version ^d submodels.^/", mrds_data_$dsmd_version_number); 473 474 cmdsm_source_path = ""; 475 mrds_dsm_display_info_ptr = null; 476 mrds_dsm_parse_info_ptr = null; 477 478 /* process arguments */ 479 480 call cu_$arg_count (nargs); 481 if nargs < 2 482 then do; 483 call com_err_ (error_table_$wrong_no_of_args, MYNAME, USAGE); 484 goto exit; 485 end; 486 487 do arg_index = 1 to nargs; 488 call cu_$arg_ptr (arg_index, arg_ptr, arg_len, code); 489 if code ^= 0 490 then do; 491 call com_err_ (code, MYNAME, "^/Error while processing argument ^i", arg_index); 492 goto exit; 493 end; 494 if substr (arg, 1, 1) = "-" 495 then do; 496 if arg = "-list" | arg = "-ls" 497 then produce_listing = "1"b; 498 else 499 if arg = "-no_list" | arg = "-nls" 500 then produce_listing = "0"b; 501 else 502 if arg = "-install" | arg = "-ins" 503 then install = "1"b; 504 else 505 if arg = "-no_install" | arg = "-nins" 506 then install = "0"b; 507 else 508 if arg = "-force" | arg = "-fc" 509 then force = "1"b; 510 else 511 if arg = "-no_force" | arg = "-nfc" 512 then force = "0"b; 513 else do; 514 call com_err_ (error_table_$bad_arg, MYNAME, "^/Unrecognizable control argument ^a", arg); 515 goto exit; 516 end; 517 end; 518 else do; 519 if cmdsm_source_path = "" 520 then cmdsm_source_path = arg; 521 else 522 if db_path = "" 523 then db_path = arg; 524 else do; 525 call com_err_ (0, MYNAME, "Extra path supplied ^a" || USAGE, arg); 526 goto exit; 527 end; 528 end; 529 end; 530 531 if db_path = "" 532 then do; 533 call com_err_ (error_table_$wrong_no_of_args, MYNAME, USAGE); 534 goto exit; 535 end; 536 537 /* process database path */ 538 539 call mrds_dsl_get_version$get_path_info (db_path, addr (local_area), 540 mrds_path_info_structure_version, mrds_path_info_ptr, code); 541 if code = mrds_error_$no_model_submodel 542 then do; 543 call com_err_ (mrds_error_$no_database, MYNAME, "^/^a is not a valid database path", db_path); 544 call finish; 545 end; 546 else 547 if code = mrds_error_$version_3_db 548 then do; 549 call com_err_ (code, MYNAME, "^/^a", db_path); 550 call finish; 551 end; 552 else 553 if code ^= 0 554 then do; 555 call com_err_ (code, MYNAME, "^/Unable to get version info for ^a", db_path); 556 call finish; 557 end; 558 559 db_path = mrds_path_info.absolute_path; 560 if ^mrds_path_info.model 561 then do; 562 call com_err_ (mrds_error_$no_database, MYNAME, "^/^a is not a valid database path", db_path); 563 call finish; 564 end; 565 566 call mrds_dm_open (db_path, 2, data_model_ptr, code); 567 if code ^= 0 568 then do; 569 call com_err_ (code, MYNAME, "^/Unable to open the database ^a", db_path); 570 call finish; 571 end; 572 573 call mrds_dm_db_secured$get_secured_status (data_model_ptr, addr (local_area), 574 database_state_structure_version, database_state_ptr, code); 575 if code ^= 0 576 then do; 577 call com_err_ (code, MYNAME, "^/Unable to get secured state of database ^a", db_path); 578 call finish; 579 end; 580 581 call mrds_dm_authorization$get_user_class (db_path, addr (local_area), 582 mrds_authorization_structure_version, mrds_authorization_ptr, code); 583 if code ^= 0 584 then do; 585 call com_err_ (code, MYNAME, "^/Unable to get user class for database ^a", db_path); 586 call finish; 587 end; 588 589 if database_state.secured & ^mrds_authorization.administrator 590 then do; 591 call com_err_ (error_table_$insufficient_access, MYNAME, 592 "^/Only a DBA can create a submodel for a secure database"); 593 call finish; 594 end; 595 596 if database_state.secured & ^install & mrds_authorization.administrator 597 then call com_err_ (0, MYNAME, 598 "^/WARNING: You are not installing this submodel which is defined for a secure database"); 599 600 if install 601 then do; 602 if ^mrds_authorization.administrator 603 then do; 604 call com_err_ (error_table_$insufficient_access, MYNAME, 605 "^/Only a DBA may install a submodel"); 606 call finish; 607 end; 608 609 call hcs_$status_ (db_path, mrds_data_$submodel_dir_name, DONT_CHASE_LINKS, addr (status_stuff), 610 null (), code); 611 if code = error_table_$noentry 612 then do; 613 ring = get_ring_ (); 614 user_id = get_group_id_$tag_star (); 615 ring_array (1) = ring; 616 ring_array (2) = ring; 617 ring_array (3) = ring; 618 call hcs_$append_branchx (db_path, mrds_data_$submodel_dir_name, fixed (SMA_MODE_VALUE), 619 ring_array, user_id, CREATE_A_DIRECTORY, DONT_COPY, 0, code); 620 if code ^= 0 621 then do; 622 call com_err_ (code, MYNAME, "^/Unable to create the submodel directory in ^a", db_path); 623 call finish; 624 end; 625 end; 626 else 627 if code ^= 0 628 then do; 629 call com_err_ (code, MYNAME, "^/Unable to determine access to the submodel directory in ^a", db_path); 630 call finish; 631 end; 632 else do; 633 if status_stuff.short.mode ^= SMA_MODE_VALUE 634 then do; 635 call mrds_dm_authorization$set_needed_access (db_path, code); 636 if code ^= 0 637 then do; 638 call com_err_ (code, MYNAME, "^/Unable to set needed access in the database ^a", db_path); 639 call finish; 640 end; 641 end; 642 end; 643 644 if length (rtrim (db_path)) + 1 + length (rtrim (mrds_data_$submodel_dir_name)) > length (dsm_dir) 645 then do; 646 call com_err_ (error_table_$pathlong, MYNAME, "^/^a>^a exceeds the maximum path length of ^d.", 647 db_path, mrds_data_$submodel_dir_name, length (dsm_dir)); 648 call finish; 649 end; 650 651 dsm_dir = rtrim (db_path) || ">" || rtrim (mrds_data_$submodel_dir_name); 652 end; 653 else dsm_dir = get_wdir_ (); 654 655 /* submodel path processing */ 656 657 call expand_pathname_$add_suffix (cmdsm_source_path, CMDSM_SUFFIX, cmdsm_source_dir, cmdsm_source_entry, code); 658 if code ^= 0 659 then do; 660 call com_err_ (code, MYNAME, "^/Could not use the string ^a as a data submodel pathname.", 661 cmdsm_source_path); 662 call finish; 663 end; 664 665 call hcs_$initiate_count (cmdsm_source_dir, cmdsm_source_entry, "", cmdsm_source_bc, 1, cmdsm_source_ptr, code); 666 if cmdsm_source_ptr = null 667 then do; 668 call com_err_ (code, MYNAME, "^/Cannot find the submodel source ^a>^a", cmdsm_source_dir, cmdsm_source_entry); 669 call finish; 670 end; 671 672 if cmdsm_source_bc = 0 673 then do; 674 call com_err_ (error_table_$empty_file, MYNAME, "^/The source file cannot be empty: ^a>^a.", cmdsm_source_dir, 675 cmdsm_source_entry); 676 call finish; 677 end; 678 679 call suffixed_name_$new_suffix (cmdsm_source_entry, CMDSM_SUFFIX, DSM_SUFFIX, dsm_name, code); 680 if code ^= 0 681 then do; 682 call com_err_ (code, MYNAME, "^/Unable to make submodel name."); 683 call finish; 684 end; 685 686 if install 687 then do; 688 if length (rtrim (dsm_dir)) + 1 + length (rtrim (dsm_name)) > length (dsm_path) 689 then do; 690 call com_err_ (error_table_$pathlong, MYNAME, "^/^a>^a exceeded the maximum path length of ^d.", dsm_dir, 691 dsm_name, length (dsm_path)); 692 call finish; 693 end; 694 dsm_path = pathname_ (dsm_dir, dsm_name); 695 end; 696 else do; 697 call absolute_pathname_ (dsm_name, dsm_path, code); 698 if code ^= 0 699 then do; 700 call com_err_ (code, MYNAME, "^/Unable to make pathname for submodel: ^a.", dsm_name); 701 call finish; 702 end; 703 end; 704 705 call mrds_dsm_define_temp (dsm_path, dsm_iocb_ptr, code); 706 if code = error_table_$namedup 707 then do; 708 call mrds_dsm_open$read (dsm_path, dsm_iocb_ptr, code); 709 if code = 0 710 then do; 711 call mrds_dsm_close$force (dsm_iocb_ptr); 712 if force 713 then call nd_handler_$force (MYNAME, dsm_dir, dsm_name, code); 714 else call nd_handler_ (MYNAME, dsm_dir, dsm_name, code); 715 if code = error_table_$action_not_performed 716 then call finish; 717 else 718 if code ^= 0 719 then do; 720 call com_err_ (code, MYNAME, 721 "^/Unable to do name duplication processing on the submodel entry ^a.", dsm_path); 722 call finish; 723 end; 724 else call mrds_dsm_define_temp (dsm_path, dsm_iocb_ptr, code); 725 end; 726 else do; 727 call com_err_ (code, MYNAME, "^/^a already exists and is not a submodel", dsm_path); 728 call finish; 729 end; 730 end; 731 732 if code ^= 0 733 then do; 734 call com_err_ (code, MYNAME, "^/Unable to create submodel entry ^a.", dsm_path); 735 call finish; 736 end; 737 738 delete_dsm = "1"b; 739 740 /* process the listing segment path and iocb's */ 741 742 if produce_listing 743 then do; 744 call expand_pathname_ (cmdsm_source_path, cmdsm_source_dir, cmdsm_source_entry, code); 745 if code ^= 0 746 then do; 747 call com_err_ (code, MYNAME, "^/Unable to expand the cmdsm source path"); 748 call finish; 749 end; 750 751 call suffixed_name_$new_suffix (cmdsm_source_entry, CMDSM_SUFFIX, LISTING_SUFFIX, listing_entry, code); 752 if code ^= 0 753 then do; 754 call com_err_ (code, MYNAME, "^/Unable to make listing name."); 755 call finish; 756 end; 757 758 listing_dir = get_wdir_ (); 759 call hcs_$initiate (listing_dir, listing_entry, "", 0, 1, listing_ptr, code); 760 if listing_ptr ^= null () 761 then do; 762 call hcs_$truncate_seg (listing_ptr, 0, code); 763 if code ^= 0 764 then do; 765 call com_err_ (code, MYNAME, "^/Unable to truncate the already existing listing segment ^a>^a", 766 listing_dir, listing_entry); 767 call finish; 768 end; 769 end; 770 else do; 771 call hcs_$make_seg (listing_dir, listing_entry, "", 14, listing_ptr, code); 772 if code ^= 0 773 then do; 774 call com_err_ (code, MYNAME, "^/Unable to create the listing segment ^a>^a", 775 listing_dir, listing_entry); 776 call finish; 777 end; 778 else delete_listing = "1"b; 779 end; 780 781 call iox_$attach_name (listing_entry, listing_iocb_ptr, "vfile_ " || listing_entry, null, code); 782 if code ^= 0 783 then do; 784 call com_err_ (code, MYNAME, "^/Unable to attach to the listing segment."); 785 call finish; 786 end; 787 call iox_$open (listing_iocb_ptr, STREAM_OUTPUT, "0"b, code); 788 if code ^= 0 789 then do; 790 call com_err_ (code, MYNAME, "^/Unable to open the listing segment switch."); 791 call finish; 792 end; 793 end; 794 795 /* set up the working area */ 796 797 allocate area_info; 798 area_info.version = 1; 799 800 call get_temp_segment_ (MYNAME, temp_seg_ptr, code); 801 if code ^= 0 802 then do; 803 call com_err_ (code, MYNAME, "^/Unable to get temporary segments."); 804 call finish; 805 end; 806 work_area_ptr = temp_seg_ptr; 807 area_info.extend = "1"b; 808 area_info.owner = MYNAME; 809 area_info.size = sys_info$max_seg_size; 810 area_info.areap = work_area_ptr; 811 area_info.zero_on_alloc = "1"b; 812 call define_area_ (area_infop, code); 813 if code ^= 0 814 then do; 815 call com_err_ (code, MYNAME, "^/Unable to define area on temporary segment at ^p.", work_area_ptr); 816 call finish; 817 end; 818 free area_info; 819 820 /* parse the cmdsm source */ 821 822 allocate mrds_dsm_parse_info in (work_area); 823 mrds_dsm_parse_info.version = MRDS_DSM_PARSE_INFO_VERSION_1; 824 mrds_dsm_parse_info.debug_parse = control_debug_parse; 825 mrds_dsm_parse_info.debug_semantics = control_debug_semantics; 826 mrds_dsm_parse_info.debug_scanner = control_debug_scanner; 827 mrds_dsm_parse_info.work_area_ptr = work_area_ptr; 828 mrds_dsm_parse_info.listing_iocb_ptr = listing_iocb_ptr; 829 mrds_dsm_parse_info.submodel_iocb_ptr = dsm_iocb_ptr; 830 mrds_dsm_parse_info.source_ptr = cmdsm_source_ptr; 831 mrds_dsm_parse_info.source_length = divide (cmdsm_source_bc, 9, 17, 0); 832 mrds_dsm_parse_info.error_iocb_ptr = iox_$error_output; 833 mrds_dsm_parse_info.data_model_ptr = data_model_ptr; 834 mrds_dsm_parse_info.highest_severity = 0; 835 mrds_dsm_parse_info.highest_severity_scanner = 0; 836 mrds_dsm_parse_info.highest_severity_semantics = 0; 837 838 delete_listing = "0"b; 839 840 call mrds_dsm_parse (mrds_dsm_parse_info_ptr, code); 841 if code ^= 0 842 then do; 843 call com_err_ (code, MYNAME, "^/Unable to parse."); 844 call finish; 845 end; 846 847 max_severity = max (mrds_dsm_parse_info.highest_severity, 848 mrds_dsm_parse_info.highest_severity_scanner, 849 mrds_dsm_parse_info.highest_severity_semantics); 850 if max_severity = 0 then do; 851 852 call mrds_dsm_write_header (dsm_iocb_ptr, db_path, code); 853 if code ^= 0 854 then do; 855 call com_err_ (code, MYNAME, "^/Unable to write the submodel header record in the submodel: ^a.", dsm_name); 856 call finish; 857 end; 858 859 call mrds_dsm_close (dsm_iocb_ptr, code); 860 if code ^= 0 861 then do; 862 call com_err_ (code, MYNAME, "^/Unable to close the switch for the submodel, ^a.", dsm_path); 863 call finish; 864 end; 865 866 call mrds_dsm_compute_access (MYNAME, dsm_path, listing_iocb_ptr, data_model_ptr, code); 867 if code ^= 0 868 then do; 869 call com_err_ (code, MYNAME, "^/Unable to compute the access within the submodel."); 870 call finish; 871 end; 872 end; 873 874 /* produce the listing */ 875 876 if produce_listing & max_severity = 0 877 then do; 878 allocate mrds_dsm_display_info in (work_area); 879 unspec (mrds_dsm_display_info) = "0"b; 880 mrds_dsm_display_info.version = MRDS_DSM_DISPLAY_INFO_VERSION; 881 mrds_dsm_display_info.submodel_pathname = dsm_path; 882 mrds_dsm_display_info.rel_names_array_ptr = null; 883 mrds_dsm_display_info.output_iocb_ptr = mrds_dsm_parse_info.listing_iocb_ptr; 884 mrds_dsm_display_info.format = "l"; 885 mrds_dsm_display_info.access = "1"b; 886 mrds_dsm_display_info.administrator = "1"b; 887 888 call mrds_dsm_open$read (mrds_dsm_display_info.submodel_pathname, 889 mrds_dsm_display_info.submodel_iocb_ptr, code); 890 if code ^= 0 891 then do; 892 call com_err_ (code, MYNAME, "^/Unable to re-open temporary submodel for creating display."); 893 call finish; 894 end; 895 896 call mrds_dsm_dmdsm (mrds_dsm_display_info_ptr, code); 897 if code ^= 0 898 then do; 899 call com_err_ (code, MYNAME, "^/Unable to append submodel display to listing."); 900 call finish; 901 end; 902 end; 903 904 /* finish up */ 905 906 if max_severity = 0 then 907 delete_dsm = "0"b; 908 else do; /* error occured */ 909 call ioa_ ("^/An error of severity ^d occured.^/Submodel not created.^/", max_severity); 910 if produce_listing then 911 call ioa_$ioa_switch (mrds_dsm_parse_info.listing_iocb_ptr, 912 "^/An error of severity ^d occured.^/Submodel not created.^/", max_severity); 913 end; 914 915 call finish; 916 917 exit: 918 return; 919 920 finish: proc; 921 922 if data_model_ptr ^= null () 923 then do; 924 call mrds_dm_close (data_model_ptr, code); 925 if code ^= 0 926 then call com_err_ (code, MYNAME, "^/Unable to close the database model"); 927 end; 928 929 if listing_iocb_ptr ^= null 930 then do; 931 call iox_$close (listing_iocb_ptr, code); 932 call iox_$detach_iocb (listing_iocb_ptr, code); 933 call iox_$destroy_iocb (listing_iocb_ptr, code); 934 end; 935 936 if delete_listing 937 then call hcs_$delentry_file (listing_dir, listing_entry, code); 938 939 if dsm_iocb_ptr ^= null 940 then call mrds_dsm_close$force (dsm_iocb_ptr); 941 942 if delete_dsm 943 then do; 944 call hcs_$del_dir_tree (dsm_dir, dsm_name, code); /* delete the msf components */ 945 if code = 0 | code = error_table_$no_dir 946 then call hcs_$delentry_file (dsm_dir, dsm_name, code); 947 end; 948 949 if cmdsm_source_ptr ^= null 950 then call hcs_$terminate_noname (cmdsm_source_ptr, code); 951 952 if mrds_dsm_parse_info_ptr ^= null () 953 then free mrds_dsm_parse_info in (work_area); 954 955 if mrds_dsm_display_info_ptr ^= null 956 then do; 957 if mrds_dsm_display_info.submodel_iocb_ptr ^= null 958 then call mrds_dsm_close$force (mrds_dsm_display_info.submodel_iocb_ptr); 959 960 free mrds_dsm_display_info in (work_area); 961 end; 962 963 if temp_seg_ptr ^= null 964 then do; 965 call release_temp_segment_ (MYNAME, temp_seg_ptr, code); 966 if code ^= 0 967 then do; 968 call com_err_ (code, MYNAME, "^/Unable to release temporary segments."); 969 end; 970 end; 971 goto exit; 972 973 end /* finish */; 974 1 1 /* BEGIN INCLUDE FILE mrds_dsm_display_info.incl.pl1 - - reb 05/19/81 */ 1 2 1 3 /* DESCRIPTION: 1 4* 1 5* Used to control the behavior of mrds_dsm_dmdsm. 1 6* 1 7**/ 1 8 1 9 dcl 1 mrds_dsm_display_info based (mrds_dsm_display_info_ptr), 1 10 2 version fixed bin (35), /* version number of this structure */ 1 11 2 submodel_pathname char (168), /* What submodel am I working with? */ 1 12 2 submodel_iocb_ptr ptr, /* To the open submodel */ 1 13 2 rel_names_array_ptr ptr, /* To the array of submodel relations names */ 1 14 2 output_iocb_ptr ptr, /* To the output switch */ 1 15 2 format char (1) unal, /* "b" => brief format 1 16* "c" => cmdsm format 1 17* "l" => long format 1 18* "r" => only submodel relation names */ 1 19 2 char_pad char (3) unal, 1 20 2 access bit (1) unal, /* ON => display access info */ 1 21 2 administrator bit (1) unal, /* ON => user is a DBA */ 1 22 2 db_secured bit (1) unal, /* ON => the database is in a secure state */ 1 23 2 submodel_secured bit (1) unal, /* ON => the submodel is in the secure.submodels 1 24* directory under the database directory */ 1 25 2 bit_pad bit (32) unal; 1 26 1 27 dcl MRDS_DSM_DISPLAY_INFO_VERSION fixed bin (35) int static options (constant) init (1); 1 28 /* current structure version for mrds_dsm_display_info */ 1 29 1 30 dcl mrds_dsm_display_info_ptr ptr; 1 31 1 32 /* END INCLUDE FILE - mrds_dsm_display_info.incl.pl1 */ 975 976 2 1 /* BEGIN INCLUDE FILE area_info.incl.pl1 12/75 */ 2 2 2 3 dcl area_info_version_1 fixed bin static init (1) options (constant); 2 4 2 5 dcl area_infop ptr; 2 6 2 7 dcl 1 area_info aligned based (area_infop), 2 8 2 version fixed bin, /* version number for this structure is 1 */ 2 9 2 control aligned like area_control, /* control bits for the area */ 2 10 2 owner char (32) unal, /* creator of the area */ 2 11 2 n_components fixed bin, /* number of components in the area (returned only) */ 2 12 2 size fixed bin (18), /* size of the area in words */ 2 13 2 version_of_area fixed bin, /* version of area (returned only) */ 2 14 2 areap ptr, /* pointer to the area (first component on multisegment area) */ 2 15 2 allocated_blocks fixed bin, /* number of blocks allocated */ 2 16 2 free_blocks fixed bin, /* number of free blocks not in virgin */ 2 17 2 allocated_words fixed bin (30), /* number of words allocated in the area */ 2 18 2 free_words fixed bin (30); /* number of words free in area not in virgin */ 2 19 2 20 dcl 1 area_control aligned based, 2 21 2 extend bit (1) unal, /* says area is extensible */ 2 22 2 zero_on_alloc bit (1) unal, /* says block gets zerod at allocation time */ 2 23 2 zero_on_free bit (1) unal, /* says block gets zerod at free time */ 2 24 2 dont_free bit (1) unal, /* debugging aid, turns off free requests */ 2 25 2 no_freeing bit (1) unal, /* for allocation method without freeing */ 2 26 2 system bit (1) unal, /* says area is managed by system */ 2 27 2 pad bit (30) unal; 2 28 2 29 /* END INCLUDE FILE area_info.incl.pl1 */ 977 978 3 1 /* BEGIN INCLUDE FILE - mrds_dsm_parse_info.incl.pl1 */ 3 2 3 3 /* 3 4*This structure is used to communicate with mrds_dsm_parse. 3 5* 3 6*79-12-19 Spratt: written 3 7* 3 8*81-05-07 Davids: added the data_model_ptr element 3 9* 3 10*81-05-15 Davids: added the highest_severity_scanner and 3 11*. highest_severity_semantics elements. 3 12**/ 3 13 3 14 dcl mrds_dsm_parse_info_ptr 3 15 ptr; 3 16 dcl MRDS_DSM_PARSE_INFO_VERSION_1 3 17 fixed bin (17) internal static options (constant) init (1); 3 18 3 19 dcl 1 mrds_dsm_parse_info based (mrds_dsm_parse_info_ptr) aligned, 3 20 2 version fixed bin (35), 3 21 2 flags, 3 22 3 debug_parse bit (1) unal, 3 23 3 debug_semantics bit (1) unal, 3 24 3 debug_scanner bit (1) unal, 3 25 3 pad bit (33) unal, 3 26 2 work_area_ptr ptr, 3 27 2 submodel_iocb_ptr ptr, 3 28 2 error_iocb_ptr ptr, 3 29 2 listing_iocb_ptr ptr, 3 30 2 source_ptr ptr, 3 31 2 source_length fixed bin (35), 3 32 2 highest_severity fixed bin, 3 33 2 data_model_ptr ptr, 3 34 2 highest_severity_scanner 3 35 fixed bin, 3 36 2 highest_severity_semantics 3 37 fixed bin; 3 38 3 39 /* END INCLUDE FILE - mrds_dsm_parse_info.incl.pl1 */ 979 980 4 1 /* BEGIN INCLUDE FILE mrds_database_state.incl.pl1 - - 81-01-20 Jim Gray */ 4 2 4 3 /* HISTORY: 4 4* 4 5* 81-01-20 Jim Gray : original created for the mmi_$get_secured_status interface 4 6* 4 7**/ 4 8 4 9 /* DESCRIPTION: 4 10* 4 11* This structure returns the database state (secured or unsecured) 4 12* for determining how commands and subroutines will behave for each case. 4 13* The secured bit was kept separate from the unsecured, 4 14* rather than it's logical "not", to allow for future extensibility 4 15* of database secured states. 4 16* 4 17**/ 4 18 4 19 4 20 declare 1 database_state aligned based (database_state_ptr), 4 21 2 version fixed bin, /* version number of this structure */ 4 22 2 unsecured bit (1) unal, /* database not secured */ 4 23 2 secured bit (1) unal, /* database has been secured */ 4 24 2 mbz bit (34) unal ; 4 25 4 26 4 27 declare database_state_ptr ptr ; /* pointer for referring to the structure */ 4 28 4 29 declare database_state_structure_version fixed bin init (1) int static options (constant) ; 4 30 4 31 /* END INCLUDE FILE mrds_database_state.incl.pl1 */ 981 982 5 1 /* BEGIN INCLUDE FILE mrds_authorization.incl.pl1 - - 81-01-20 Jim Gray */ 5 2 5 3 /* HISTORY: 5 4* 5 5* 81-01-20 Jim Gray : original created for the mmi_$get_authorization interface 5 6* 5 7**/ 5 8 5 9 /* DESCRIPTION: 5 10* 5 11* this structure returns the callers user_class 5 12* either database administrator or normal user. 5 13* Note that these separate classes were used to allow 5 14* future expansion to the user classes, rather than 5 15* make them logical "not"'s of one another. 5 16* NOTE: a DBA is always also a normal user, thus if the caller 5 17* is a DBA, his normal_user bit will be on also. 5 18* 5 19**/ 5 20 5 21 5 22 declare 1 mrds_authorization aligned based (mrds_authorization_ptr), 5 23 2 version fixed bin, /* version number of this structure */ 5 24 2 administrator bit (1) unal, /* caller is a DBA */ 5 25 2 normal_user bit (1) unal, /* caller has no special priviledges */ 5 26 2 mbz bit (34) unal ; 5 27 5 28 5 29 declare mrds_authorization_ptr ptr ; /* pointer for referring to the structure */ 5 30 5 31 declare mrds_authorization_structure_version fixed bin init (1) int static options (constant) ; 5 32 5 33 /* END INCLUDE FILE mrds_authorization.incl.pl1 */ 983 984 6 1 /* BEGIN INCLUDE FILE mrds_path_info.incl.pl1 - - Jim Gray 81-01-22 */ 6 2 6 3 /* HISTORY: 6 4* 6 5* 81-01-22 Jim Gray : originaly created for the dsl_$get_path_info interface, 6 6* a slight extension to the undocumented mrds_dsl_get_version$header. 6 7* 6 8**/ 6 9 6 10 /* DESCRIPTION: 6 11* 6 12* This structure returns information about a relative pathname, given 6 13* to a pathname accepting mrds interface. The information returned 6 14* is the absolute pathname, plus in the case that 6 15* the relative path points to a mrds database or submodel 6 16* whether it is a model or a submodel, the mrds version of 6 17* the model or submodel, it's creator, and the time of creation. 6 18* 6 19**/ 6 20 6 21 6 22 declare 1 mrds_path_info aligned based (mrds_path_info_ptr), 6 23 2 version fixed bin, /* version number for this structure */ 6 24 2 absolute_path char (168), /* the absolute path from the input relative path */ 6 25 2 type, 6 26 3 not_mrds bit (1) unal, /* on => path not to model or submodel */ 6 27 3 model bit (1) unal, /* on => path to database model, thus possible .db suffix */ 6 28 3 submodel bit (1) unal, /* on => path to submodel, thus possible .dsm suffix */ 6 29 3 mbz1 bit (33) unal, 6 30 2 mrds_version fixed bin, /* the mrds version number of the model or submodel */ 6 31 2 creator_id char (32), /* the person.project.tag of the creator */ 6 32 2 creation_time fixed bin (71), /* convert date to binary form of time model/submodel created */ 6 33 2 mbz2 bit (36) unal ; 6 34 6 35 6 36 declare mrds_path_info_ptr ptr ; 6 37 6 38 declare mrds_path_info_structure_version fixed bin init (1) int static options (constant) ; 6 39 6 40 /* END INCLUDE FILE mrds_path_info.incl.pl1 */ 985 986 7 1 /* --------------- BEGIN include file status_structures.incl.pl1 --------------- */ 7 2 7 3 /* Revised from existing include files 09/26/78 by C. D. Tavares */ 7 4 7 5 /* This include file contains branch and link structures returned by 7 6* hcs_$status_ and hcs_$status_long. */ 7 7 7 8 dcl 1 status_branch aligned based (status_ptr), 7 9 2 short aligned, 7 10 3 type fixed bin (2) unaligned unsigned, /* seg, dir, or link */ 7 11 3 nnames fixed bin (16) unaligned unsigned, /* number of names */ 7 12 3 names_relp bit (18) unaligned, /* see entry_names dcl */ 7 13 3 dtcm bit (36) unaligned, /* date/time contents last modified */ 7 14 3 dtu bit (36) unaligned, /* date/time last used */ 7 15 3 mode bit (5) unaligned, /* caller's effective access */ 7 16 3 raw_mode bit (5) unaligned, /* caller's raw "rew" modes */ 7 17 3 pad1 bit (8) unaligned, 7 18 3 records_used fixed bin (18) unaligned unsigned, /* number of NONZERO pages used */ 7 19 7 20 /* Limit of information returned by hcs_$status_ */ 7 21 7 22 2 long aligned, 7 23 3 dtd bit (36) unaligned, /* date/time last dumped */ 7 24 3 dtem bit (36) unaligned, /* date/time branch last modified */ 7 25 3 lvid bit (36) unaligned, /* logical volume ID */ 7 26 3 current_length fixed bin (12) unaligned unsigned, /* number of last page used */ 7 27 3 bit_count fixed bin (24) unaligned unsigned, /* reported length in bits */ 7 28 3 pad2 bit (8) unaligned, 7 29 3 copy_switch bit (1) unaligned, /* copy switch */ 7 30 3 tpd_switch bit (1) unaligned, /* transparent to paging device switch */ 7 31 3 mdir_switch bit (1) unaligned, /* is a master dir */ 7 32 3 damaged_switch bit (1) unaligned, /* salvager warned of possible damage */ 7 33 3 synchronized_switch bit (1) unaligned, /* DM synchronized file */ 7 34 3 pad3 bit (5) unaligned, 7 35 3 ring_brackets (0:2) fixed bin (6) unaligned unsigned, 7 36 3 uid bit (36) unaligned; /* unique ID */ 7 37 7 38 dcl 1 status_link aligned based (status_ptr), 7 39 2 type fixed bin (2) unaligned unsigned, /* as above */ 7 40 2 nnames fixed bin (16) unaligned unsigned, 7 41 2 names_relp bit (18) unaligned, 7 42 2 dtem bit (36) unaligned, 7 43 2 dtd bit (36) unaligned, 7 44 2 pathname_length fixed bin (17) unaligned, /* see pathname */ 7 45 2 pathname_relp bit (18) unaligned; /* see pathname */ 7 46 7 47 dcl status_entry_names (status_branch.nnames) character (32) aligned 7 48 based (pointer (status_area_ptr, status_branch.names_relp)), 7 49 /* array of names returned */ 7 50 status_pathname character (status_link.pathname_length) aligned 7 51 based (pointer (status_area_ptr, status_link.pathname_relp)), 7 52 /* link target path */ 7 53 status_area_ptr pointer, 7 54 status_ptr pointer; 7 55 7 56 dcl (Link initial (0), 7 57 Segment initial (1), 7 58 Directory initial (2)) fixed bin internal static options (constant); 7 59 /* values for type fields declared above */ 7 60 7 61 /* ---------------- END include file status_structures.incl.pl1 ---------------- */ 987 988 989 990 end /* create_mrds_dsm */; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 08/15/86 1437.0 create_mrds_dsm.pl1 >special_ldd>install>MR12.0-1127>create_mrds_dsm.pl1 975 1 10/14/83 1609.0 mrds_dsm_display_info.incl.pl1 >ldd>include>mrds_dsm_display_info.incl.pl1 977 2 06/11/76 1043.4 area_info.incl.pl1 >ldd>include>area_info.incl.pl1 979 3 10/14/83 1608.9 mrds_dsm_parse_info.incl.pl1 >ldd>include>mrds_dsm_parse_info.incl.pl1 981 4 10/14/83 1608.8 mrds_database_state.incl.pl1 >ldd>include>mrds_database_state.incl.pl1 983 5 10/14/83 1608.8 mrds_authorization.incl.pl1 >ldd>include>mrds_authorization.incl.pl1 985 6 10/14/83 1608.8 mrds_path_info.incl.pl1 >ldd>include>mrds_path_info.incl.pl1 987 7 11/22/82 0955.7 status_structures.incl.pl1 >ldd>include>status_structures.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. CMDSM_SUFFIX 000026 constant char(5) initial unaligned dcl 388 set ref 657* 679* 751* CREATE_A_DIRECTORY 000117 constant fixed bin(1,0) initial dcl 389 set ref 618* DONT_CHASE_LINKS 000106 constant fixed bin(1,0) initial dcl 390 set ref 609* DONT_COPY 000106 constant fixed bin(1,0) initial dcl 391 set ref 618* DSM_SUFFIX 000024 constant char(3) initial unaligned dcl 392 set ref 679* LISTING_SUFFIX 000023 constant char(4) initial unaligned dcl 393 set ref 751* MRDS_DSM_DISPLAY_INFO_VERSION constant fixed bin(35,0) initial dcl 1-27 ref 880 MRDS_DSM_PARSE_INFO_VERSION_1 constant fixed bin(17,0) initial dcl 3-16 ref 823 MYNAME 000017 constant char(15) initial unaligned dcl 394 set ref 483* 491* 514* 525* 533* 543* 549* 555* 562* 569* 577* 585* 591* 596* 604* 622* 629* 638* 646* 660* 668* 674* 682* 690* 700* 712* 714* 720* 727* 734* 747* 754* 765* 774* 784* 790* 800* 803* 808 815* 843* 855* 862* 866* 869* 892* 899* 925* 965* 968* SMA_MODE_VALUE constant bit(5) initial unaligned dcl 395 ref 618 618 633 STREAM_OUTPUT 000111 constant fixed bin(17,0) initial dcl 396 set ref 787* USAGE 000000 constant char(60) initial unaligned dcl 397 set ref 483* 525 533* absolute_path 1 based char(168) level 2 dcl 6-22 ref 559 absolute_pathname_ 000010 constant entry external dcl 401 ref 697 access 63 based bit(1) level 2 packed unaligned dcl 1-9 set ref 885* addr builtin function dcl 371 ref 539 539 573 573 581 581 609 609 administrator 1 based bit(1) level 2 in structure "mrds_authorization" packed unaligned dcl 5-22 in procedure "cmdsm" ref 589 596 602 administrator 63(01) based bit(1) level 2 in structure "mrds_dsm_display_info" packed unaligned dcl 1-9 in procedure "cmdsm" set ref 886* area_control based structure level 1 dcl 2-20 area_info based structure level 1 dcl 2-7 set ref 797 818 area_infop 002644 automatic pointer dcl 2-5 set ref 797* 798 807 808 809 810 811 812* 818 areap 16 based pointer level 2 dcl 2-7 set ref 810* arg based char unaligned dcl 366 set ref 494 496 496 498 498 501 501 504 504 507 507 510 510 514* 519 521 525* arg_index 000100 automatic fixed bin(17,0) dcl 312 set ref 487* 488* 491* arg_len 000101 automatic fixed bin(21,0) dcl 313 set ref 488* 494 496 496 498 498 501 501 504 504 507 507 510 510 514 514 519 521 525 525 arg_ptr 000102 automatic pointer dcl 314 set ref 488* 494 496 496 498 498 501 501 504 504 507 507 510 510 514 519 521 525 cleanup 002634 stack reference condition dcl 384 ref 470 cmdsm_source_bc 000104 automatic fixed bin(24,0) dcl 316 set ref 665* 672 831 cmdsm_source_dir 000105 automatic char(168) unaligned dcl 317 set ref 657* 665* 668* 674* 744* cmdsm_source_entry 000157 automatic char(32) unaligned dcl 318 set ref 657* 665* 668* 674* 679* 744* 751* cmdsm_source_path 000167 automatic char(168) unaligned dcl 319 set ref 474* 519 519* 657* 660* 744* cmdsm_source_ptr 000242 automatic pointer initial dcl 320 set ref 320* 665* 666 830 949 949* code 000244 automatic fixed bin(35,0) dcl 322 set ref 488* 489 491* 539* 541 546 549* 552 555* 566* 567 569* 573* 575 577* 581* 583 585* 609* 611 618* 620 622* 626 629* 635* 636 638* 657* 658 660* 665* 668* 679* 680 682* 697* 698 700* 705* 706 708* 709 712* 714* 715 717 720* 724* 727* 732 734* 744* 745 747* 751* 752 754* 759* 762* 763 765* 771* 772 774* 781* 782 784* 787* 788 790* 800* 801 803* 812* 813 815* 840* 841 843* 852* 853 855* 859* 860 862* 866* 867 869* 888* 890 892* 896* 897 899* 924* 925 925* 931* 932* 933* 936* 944* 945 945 945* 949* 965* 966 968* com_err_ 000012 constant entry external dcl 402 ref 483 491 514 525 533 543 549 555 562 569 577 585 591 596 604 622 629 638 646 660 668 674 682 690 700 720 727 734 747 754 765 774 784 790 803 815 843 855 862 869 892 899 925 968 control 1 based structure level 2 dcl 2-7 control_debug_parse 000245 automatic bit(1) initial unaligned dcl 324 set ref 324* 824 control_debug_scanner 000246 automatic bit(1) initial unaligned dcl 325 set ref 325* 826 control_debug_semantics 000247 automatic bit(1) initial unaligned dcl 326 set ref 326* 825 cu_$arg_count 000014 constant entry external dcl 403 ref 480 cu_$arg_ptr 000016 constant entry external dcl 404 ref 488 data_model_ptr 16 based pointer level 2 in structure "mrds_dsm_parse_info" dcl 3-19 in procedure "cmdsm" set ref 833* data_model_ptr 000250 automatic pointer initial dcl 328 in procedure "cmdsm" set ref 328* 566* 573* 833 866* 922 924* database_state based structure level 1 dcl 4-20 database_state_ptr 002650 automatic pointer dcl 4-27 set ref 573* 589 596 database_state_structure_version 000117 constant fixed bin(17,0) initial dcl 4-29 set ref 573* db_path 000252 automatic char(168) initial unaligned dcl 330 set ref 330* 521 521* 531 539* 543* 549* 555* 559* 562* 566* 569* 577* 581* 585* 609* 618* 622* 629* 635* 638* 644 646* 651 852* debug_parse 1 based bit(1) level 3 packed unaligned dcl 3-19 set ref 824* debug_scanner 1(02) based bit(1) level 3 packed unaligned dcl 3-19 set ref 826* debug_semantics 1(01) based bit(1) level 3 packed unaligned dcl 3-19 set ref 825* define_area_ 000020 constant entry external dcl 405 ref 812 delete_dsm 000324 automatic bit(1) initial unaligned dcl 332 set ref 332* 738* 906* 942 delete_listing 000325 automatic bit(1) initial unaligned dcl 333 set ref 333* 778* 838* 936 divide builtin function dcl 372 ref 831 dsm_dir 000326 automatic char(168) unaligned dcl 335 set ref 644 646 646 651* 653* 688 690* 694* 712* 714* 944* 945* dsm_iocb_ptr 000400 automatic pointer initial dcl 336 set ref 336* 705* 708* 711* 724* 829 852* 859* 939 939* dsm_name 000402 automatic char(32) unaligned dcl 337 set ref 679* 688 690* 694* 697* 700* 712* 714* 855* 944* 945* dsm_path 000412 automatic char(168) unaligned dcl 338 set ref 688 690 690 694* 697* 705* 708* 720* 724* 727* 734* 862* 866* 881 empty builtin function dcl 373 ref 348 error_iocb_ptr 6 based pointer level 2 dcl 3-19 set ref 832* error_table_$action_not_performed 000144 external static fixed bin(35,0) dcl 451 ref 715 error_table_$bad_arg 000146 external static fixed bin(35,0) dcl 452 set ref 514* error_table_$empty_file 000150 external static fixed bin(35,0) dcl 453 set ref 674* error_table_$insufficient_access 000152 external static fixed bin(35,0) dcl 454 set ref 591* 604* error_table_$namedup 000154 external static fixed bin(35,0) dcl 455 ref 706 error_table_$no_dir 000156 external static fixed bin(35,0) dcl 456 ref 945 error_table_$noentry 000160 external static fixed bin(35,0) dcl 457 ref 611 error_table_$pathlong 000162 external static fixed bin(35,0) dcl 458 set ref 646* 690* error_table_$wrong_no_of_args 000164 external static fixed bin(35,0) dcl 459 set ref 483* 533* expand_pathname_ 000022 constant entry external dcl 406 ref 744 expand_pathname_$add_suffix 000024 constant entry external dcl 407 ref 657 extend 1 based bit(1) level 3 packed unaligned dcl 2-7 set ref 807* fixed builtin function dcl 374 ref 618 618 flags 1 based structure level 2 dcl 3-19 force 000464 automatic bit(1) initial unaligned dcl 340 set ref 340* 507* 510* 712 format 62 based char(1) level 2 packed unaligned dcl 1-9 set ref 884* get_group_id_$tag_star 000026 constant entry external dcl 408 ref 614 get_ring_ 000030 constant entry external dcl 409 ref 613 get_temp_segment_ 000032 constant entry external dcl 410 ref 800 get_wdir_ 000034 constant entry external dcl 411 ref 653 758 hcs_$append_branchx 000036 constant entry external dcl 412 ref 618 hcs_$del_dir_tree 000040 constant entry external dcl 414 ref 944 hcs_$delentry_file 000042 constant entry external dcl 415 ref 936 945 hcs_$initiate 000044 constant entry external dcl 416 ref 759 hcs_$initiate_count 000046 constant entry external dcl 417 ref 665 hcs_$make_seg 000050 constant entry external dcl 418 ref 771 hcs_$status_ 000052 constant entry external dcl 419 ref 609 hcs_$terminate_noname 000054 constant entry external dcl 420 ref 949 hcs_$truncate_seg 000056 constant entry external dcl 421 ref 762 highest_severity 15 based fixed bin(17,0) level 2 dcl 3-19 set ref 834* 847 highest_severity_scanner 20 based fixed bin(17,0) level 2 dcl 3-19 set ref 835* 847 highest_severity_semantics 21 based fixed bin(17,0) level 2 dcl 3-19 set ref 836* 847 install 000465 automatic bit(1) initial unaligned dcl 341 set ref 341* 501* 504* 596 600 686 ioa_ 000060 constant entry external dcl 422 ref 472 909 ioa_$ioa_switch 000062 constant entry external dcl 423 ref 910 iox_$attach_name 000064 constant entry external dcl 424 ref 781 iox_$close 000066 constant entry external dcl 425 ref 931 iox_$destroy_iocb 000070 constant entry external dcl 426 ref 933 iox_$detach_iocb 000072 constant entry external dcl 427 ref 932 iox_$error_output 000166 external static pointer dcl 460 ref 832 iox_$open 000074 constant entry external dcl 428 ref 787 length builtin function dcl 375 ref 644 644 644 646 646 688 688 688 690 690 listing_dir 000466 automatic char(168) initial unaligned dcl 343 set ref 343* 758* 759* 765* 771* 774* 936* listing_entry 000540 automatic char(32) initial unaligned dcl 344 set ref 344* 751* 759* 765* 771* 774* 781* 781 936* listing_iocb_ptr 10 based pointer level 2 in structure "mrds_dsm_parse_info" dcl 3-19 in procedure "cmdsm" set ref 828* 883 910* listing_iocb_ptr 000550 automatic pointer initial dcl 345 in procedure "cmdsm" set ref 345* 781* 787* 828 866* 929 931* 932* 933* listing_ptr 000552 automatic pointer initial dcl 346 set ref 346* 759* 760 762* 771* local_area 000554 automatic area(1000) dcl 348 set ref 348* 539 539 573 573 581 581 max builtin function dcl 376 ref 847 max_severity 002524 automatic fixed bin(17,0) dcl 349 set ref 847* 850 876 906 909* 910* mode 3 002533 automatic bit(5) level 3 packed unaligned dcl 356 set ref 633 model 53(01) based bit(1) level 3 packed unaligned dcl 6-22 ref 560 mrds_authorization based structure level 1 dcl 5-22 mrds_authorization_ptr 002652 automatic pointer dcl 5-29 set ref 581* 589 596 602 mrds_authorization_structure_version 000117 constant fixed bin(17,0) initial dcl 5-31 set ref 581* mrds_data_$dsmd_version_number 000170 external static fixed bin(35,0) dcl 461 set ref 472* mrds_data_$submodel_dir_name 000172 external static char(16) unaligned dcl 462 set ref 609* 618* 644 646* 651 mrds_dm_authorization$get_user_class 000076 constant entry external dcl 429 ref 581 mrds_dm_authorization$set_needed_access 000100 constant entry external dcl 430 ref 635 mrds_dm_close 000104 constant entry external dcl 432 ref 924 mrds_dm_db_secured$get_secured_status 000102 constant entry external dcl 431 ref 573 mrds_dm_open 000106 constant entry external dcl 433 ref 566 mrds_dsl_get_version$get_path_info 000110 constant entry external dcl 434 ref 539 mrds_dsm_close 000112 constant entry external dcl 435 ref 859 mrds_dsm_close$force 000114 constant entry external dcl 436 ref 711 939 957 mrds_dsm_compute_access 000116 constant entry external dcl 437 ref 866 mrds_dsm_define_temp 000120 constant entry external dcl 438 ref 705 724 mrds_dsm_display_info based structure level 1 unaligned dcl 1-9 set ref 878 879* 960 mrds_dsm_display_info_ptr 002642 automatic pointer dcl 1-30 set ref 475* 878* 879 880 881 882 883 884 885 886 888 888 896* 955 957 957 960 mrds_dsm_dmdsm 000122 constant entry external dcl 439 ref 896 mrds_dsm_open$read 000124 constant entry external dcl 440 ref 708 888 mrds_dsm_parse 000126 constant entry external dcl 441 ref 840 mrds_dsm_parse_info based structure level 1 dcl 3-19 set ref 822 952 mrds_dsm_parse_info_ptr 002646 automatic pointer dcl 3-14 set ref 476* 822* 823 824 825 826 827 828 829 830 831 832 833 834 835 836 840* 847 847 847 883 910 952 952 mrds_dsm_write_header 000130 constant entry external dcl 442 ref 852 mrds_error_$no_database 000174 external static fixed bin(35,0) dcl 463 set ref 543* 562* mrds_error_$no_model_submodel 000176 external static fixed bin(35,0) dcl 464 ref 541 mrds_error_$version_3_db 000200 external static fixed bin(35,0) dcl 465 ref 546 mrds_path_info based structure level 1 dcl 6-22 mrds_path_info_ptr 002654 automatic pointer dcl 6-36 set ref 539* 559 560 mrds_path_info_structure_version 000117 constant fixed bin(17,0) initial dcl 6-38 set ref 539* nargs 002525 automatic fixed bin(17,0) dcl 350 set ref 480* 481 487 nd_handler_ 000132 constant entry external dcl 443 ref 714 nd_handler_$force 000134 constant entry external dcl 444 ref 712 null builtin function dcl 377 ref 320 328 336 345 346 359 362 475 476 609 609 666 760 781 781 882 922 929 939 949 952 955 957 963 output_iocb_ptr 60 based pointer level 2 dcl 1-9 set ref 883* owner 2 based char(32) level 2 packed unaligned dcl 2-7 set ref 808* pathname_ 000136 constant entry external dcl 445 ref 694 produce_listing 002526 automatic bit(1) initial dcl 351 set ref 351* 496* 498* 742 876 910 rel_names_array_ptr 56 based pointer level 2 dcl 1-9 set ref 882* release_temp_segment_ 000140 constant entry external dcl 446 ref 965 ring 002527 automatic fixed bin(17,0) dcl 353 set ref 613* 615 616 617 ring_array 002530 automatic fixed bin(3,0) array dcl 354 set ref 615* 616* 617* 618* rtrim builtin function dcl 378 ref 644 644 651 651 688 688 secured 1(01) based bit(1) level 2 packed unaligned dcl 4-20 ref 589 596 short 002533 automatic structure level 2 dcl 356 size 13 based fixed bin(18,0) level 2 dcl 2-7 set ref 809* source_length 14 based fixed bin(35,0) level 2 dcl 3-19 set ref 831* source_ptr 12 based pointer level 2 dcl 3-19 set ref 830* status_branch based structure level 1 dcl 7-8 status_stuff 002533 automatic structure level 1 unaligned dcl 356 set ref 609 609 submodel_iocb_ptr 54 based pointer level 2 in structure "mrds_dsm_display_info" dcl 1-9 in procedure "cmdsm" set ref 888* 957 957* submodel_iocb_ptr 4 based pointer level 2 in structure "mrds_dsm_parse_info" dcl 3-19 in procedure "cmdsm" set ref 829* submodel_pathname 1 based char(168) level 2 packed unaligned dcl 1-9 set ref 881* 888* substr builtin function dcl 379 ref 494 suffixed_name_$new_suffix 000142 constant entry external dcl 447 ref 679 751 sys_info$max_seg_size 000202 external static fixed bin(35,0) dcl 466 ref 809 temp_dsm_path 002545 automatic char(168) initial unaligned dcl 358 set ref 358* temp_seg_ptr 002620 automatic pointer initial dcl 359 set ref 359* 800* 806 963 965* type 53 based structure level 2 dcl 6-22 unspec builtin function dcl 380 set ref 879* user_id 002622 automatic char(32) unaligned dcl 361 set ref 614* 618* version based fixed bin(17,0) level 2 in structure "area_info" dcl 2-7 in procedure "cmdsm" set ref 798* version based fixed bin(35,0) level 2 in structure "mrds_dsm_display_info" dcl 1-9 in procedure "cmdsm" set ref 880* version based fixed bin(35,0) level 2 in structure "mrds_dsm_parse_info" dcl 3-19 in procedure "cmdsm" set ref 823* work_area based area dcl 367 ref 822 878 952 960 work_area_ptr 2 based pointer level 2 in structure "mrds_dsm_parse_info" dcl 3-19 in procedure "cmdsm" set ref 827* work_area_ptr 002632 automatic pointer initial dcl 362 in procedure "cmdsm" set ref 362* 806* 810 815* 822 827 878 952 960 zero_on_alloc 1(01) based bit(1) level 3 packed unaligned dcl 2-7 set ref 811* NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. Directory internal static fixed bin(17,0) initial dcl 7-56 Link internal static fixed bin(17,0) initial dcl 7-56 Segment internal static fixed bin(17,0) initial dcl 7-56 area_info_version_1 internal static fixed bin(17,0) initial dcl 2-3 status_area_ptr automatic pointer dcl 7-47 status_entry_names based char(32) array dcl 7-47 status_link based structure level 1 dcl 7-38 status_pathname based char dcl 7-47 status_ptr automatic pointer dcl 7-47 NAMES DECLARED BY EXPLICIT CONTEXT. cmdsm 001155 constant entry external dcl 21 create_mrds_dsm 001165 constant entry external dcl 21 exit 005714 constant label dcl 917 ref 484 492 515 526 534 971 finish 005716 constant entry internal dcl 920 ref 470 544 550 556 563 570 578 586 593 606 623 630 639 648 662 669 676 683 692 701 715 722 728 735 748 755 767 776 785 791 804 816 844 856 863 870 893 900 915 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 7260 7464 6277 7270 Length 10200 6277 204 500 760 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME cmdsm 1620 external procedure is an external procedure. on unit on line 470 64 on unit finish 108 internal procedure is called by several nonquick procedures. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME cmdsm 000100 arg_index cmdsm 000101 arg_len cmdsm 000102 arg_ptr cmdsm 000104 cmdsm_source_bc cmdsm 000105 cmdsm_source_dir cmdsm 000157 cmdsm_source_entry cmdsm 000167 cmdsm_source_path cmdsm 000242 cmdsm_source_ptr cmdsm 000244 code cmdsm 000245 control_debug_parse cmdsm 000246 control_debug_scanner cmdsm 000247 control_debug_semantics cmdsm 000250 data_model_ptr cmdsm 000252 db_path cmdsm 000324 delete_dsm cmdsm 000325 delete_listing cmdsm 000326 dsm_dir cmdsm 000400 dsm_iocb_ptr cmdsm 000402 dsm_name cmdsm 000412 dsm_path cmdsm 000464 force cmdsm 000465 install cmdsm 000466 listing_dir cmdsm 000540 listing_entry cmdsm 000550 listing_iocb_ptr cmdsm 000552 listing_ptr cmdsm 000554 local_area cmdsm 002524 max_severity cmdsm 002525 nargs cmdsm 002526 produce_listing cmdsm 002527 ring cmdsm 002530 ring_array cmdsm 002533 status_stuff cmdsm 002545 temp_dsm_path cmdsm 002620 temp_seg_ptr cmdsm 002622 user_id cmdsm 002632 work_area_ptr cmdsm 002642 mrds_dsm_display_info_ptr cmdsm 002644 area_infop cmdsm 002646 mrds_dsm_parse_info_ptr cmdsm 002650 database_state_ptr cmdsm 002652 mrds_authorization_ptr cmdsm 002654 mrds_path_info_ptr cmdsm THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. alloc_char_temp cat_realloc_chars call_ext_out_desc call_ext_out call_int_this call_int_other return_mac tra_ext_1 enable_op shorten_stack ext_entry int_entry op_alloc_ alloc_storage op_freen_ op_empty_ THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. absolute_pathname_ com_err_ cu_$arg_count cu_$arg_ptr define_area_ expand_pathname_ expand_pathname_$add_suffix get_group_id_$tag_star get_ring_ get_temp_segment_ get_wdir_ hcs_$append_branchx hcs_$del_dir_tree hcs_$delentry_file hcs_$initiate hcs_$initiate_count hcs_$make_seg hcs_$status_ hcs_$terminate_noname hcs_$truncate_seg ioa_ ioa_$ioa_switch iox_$attach_name iox_$close iox_$destroy_iocb iox_$detach_iocb iox_$open mrds_dm_authorization$get_user_class mrds_dm_authorization$set_needed_access mrds_dm_close mrds_dm_db_secured$get_secured_status mrds_dm_open mrds_dsl_get_version$get_path_info mrds_dsm_close mrds_dsm_close$force mrds_dsm_compute_access mrds_dsm_define_temp mrds_dsm_dmdsm mrds_dsm_open$read mrds_dsm_parse mrds_dsm_write_header nd_handler_ nd_handler_$force pathname_ release_temp_segment_ suffixed_name_$new_suffix THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$action_not_performed error_table_$bad_arg error_table_$empty_file error_table_$insufficient_access error_table_$namedup error_table_$no_dir error_table_$noentry error_table_$pathlong error_table_$wrong_no_of_args iox_$error_output mrds_data_$dsmd_version_number mrds_data_$submodel_dir_name mrds_error_$no_database mrds_error_$no_model_submodel mrds_error_$version_3_db sys_info$max_seg_size LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 320 001112 324 001114 325 001115 326 001116 328 001117 330 001120 332 001123 333 001124 336 001125 340 001126 341 001127 343 001130 344 001133 345 001136 346 001137 348 001140 351 001143 358 001144 359 001147 362 001151 21 001154 470 001173 472 001215 474 001235 475 001240 476 001242 480 001243 481 001252 483 001255 484 001276 487 001277 488 001305 489 001322 491 001324 492 001354 494 001355 496 001362 498 001376 501 001410 504 001423 507 001435 510 001450 514 001462 515 001515 517 001516 519 001517 521 001530 525 001541 526 001600 529 001601 531 001603 533 001607 534 001630 539 001631 541 001663 543 001667 544 001716 545 001722 546 001723 549 001725 550 001753 551 001757 552 001760 555 001762 556 002011 559 002015 560 002021 562 002024 563 002054 566 002060 567 002077 569 002101 570 002131 573 002135 575 002156 577 002160 578 002210 581 002214 583 002246 585 002250 586 002300 589 002304 591 002314 593 002340 596 002344 600 002403 602 002405 604 002411 606 002435 609 002441 611 002501 613 002505 614 002515 615 002524 616 002526 617 002527 618 002530 620 002604 622 002606 623 002636 625 002642 626 002643 629 002645 630 002674 631 002700 633 002701 635 002705 636 002721 638 002723 639 002753 644 002757 646 003010 648 003050 651 003054 652 003131 653 003133 657 003142 658 003172 660 003174 662 003224 665 003230 666 003273 668 003277 669 003333 672 003337 674 003341 676 003375 679 003401 680 003431 682 003433 683 003457 686 003463 688 003465 690 003514 692 003556 694 003562 695 003602 697 003603 698 003624 700 003626 701 003656 705 003662 706 003703 708 003707 709 003727 711 003731 712 003740 714 003770 715 004015 717 004026 720 004030 722 004057 723 004063 724 004064 725 004104 727 004105 728 004135 732 004141 734 004143 735 004173 738 004177 742 004201 744 004203 745 004227 747 004231 748 004255 751 004261 752 004311 754 004313 755 004337 758 004343 759 004352 760 004416 762 004422 763 004436 765 004440 767 004474 769 004500 771 004501 772 004540 774 004542 776 004576 777 004602 778 004603 781 004605 782 004645 784 004647 785 004673 787 004677 788 004716 790 004720 791 004744 797 004750 798 004754 800 004756 801 004777 803 005001 804 005025 806 005031 807 005033 808 005036 809 005041 810 005044 811 005046 812 005050 813 005060 815 005062 816 005112 818 005116 822 005120 823 005125 824 005127 825 005133 826 005140 827 005145 828 005147 829 005151 830 005153 831 005155 832 005160 833 005164 834 005166 835 005167 836 005170 838 005171 840 005172 841 005202 843 005204 844 005233 847 005237 850 005250 852 005252 853 005273 855 005275 856 005325 859 005331 860 005342 862 005344 863 005374 866 005400 867 005430 869 005432 870 005456 876 005462 878 005466 879 005473 880 005476 881 005500 882 005503 883 005505 884 005510 885 005512 886 005514 888 005516 890 005540 892 005542 893 005566 896 005572 897 005603 899 005605 900 005631 906 005635 909 005641 910 005661 915 005710 917 005714 920 005715 922 005723 924 005730 925 005740 929 005767 931 005774 932 006005 933 006017 936 006031 939 006055 942 006071 944 006074 945 006115 949 006144 952 006162 955 006171 957 006176 960 006212 963 006215 965 006222 966 006243 968 006246 971 006272 ----------------------------------------------------------- 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