?? NEWTITLE := 'pfp$write_limit_entry', EJECT ??
?? PUSH (LISTEXT := ON) ??
*copyc avt$total_limit_update_record
?? POP ??

{ PURPOSE
{   This procedure writes information about totals for accounts, projects, and users into a sequence of limit
{   information to be used to update the permanent file space accumulator in the validation file.  This
{   information is input to avp$replace_total_limits.

    PROCEDURE pfp$write_limit_entry
      (    family_name: ost$family_name;
           account_name: avt$account_name;
           project_name: avt$project_name;
           user_name: ost$user_name;
           allocated_size: integer;
       VAR number_of_limit_entries: integer;
       VAR limit_entries: ^SEQ ( * ));

      VAR
        limit_entry: ^avt$total_limit_update_record;

{ Account and project NONE are special keywords to signify no account or project.
{ No account or project can possibly be defined for them  so do not write out a limit entry.

      IF ((account_name <> 'NONE') AND (project_name <> 'NONE')) THEN
        NEXT limit_entry IN limit_entries;
        limit_entry^.family_name := family_name;
        limit_entry^.validation_key.account_name := account_name;
        limit_entry^.validation_key.project_name := project_name;
        limit_entry^.validation_key.user_name := user_name;
        limit_entry^.size := allocated_size;
        number_of_limit_entries := number_of_limit_entries + 1;
      IFEND;

    PROCEND pfp$write_limit_entry;

?? OLDTITLE, EJECT ??
