/* * * F11DEF - file header structure, ODS level 1 [not in Starlet] */ #ifndef _FH1DEF_H #define _FH1DEF_H #define FH1$C_LEVEL1 257 /* 401 octal = structure level 1 */ #define FH1$K_LENGTH 46 /* length of header area */ #define FH1$C_LENGTH 46 #define FH1$S_FH1DEF 512 #define FH1$S_FID 4 /* size (in bytes) of file ID */ #define FH1$S_SYSPRO 4 /* size (in bits) of protection fields */ #define FH1$S_OWNPRO 4 #define FH1$S_GROUPPRO 4 #define FH1$S_WORLDPRO 4 #define FH1$S_RECATTR 32 struct fh1def { unsigned char fh1$b_idoffset; /* ident area offset in words */ unsigned char fh1$b_mpoffset; /* map area offset in words */ union { unsigned short fh1$w_fid[2]; /* file ID */ struct { unsigned short fh1$w_fid_num; /* file number */ unsigned short fh1$w_fid_seq; /* file sequence number */ } fh1$r_fid_fields; } fh1$r_fid_overlay; unsigned short fh1$w_struclev; /* file structure level */ union { unsigned short fh1$w_fileowner; /* file owner UIC */ struct { unsigned char fh1$b_uicmember; /* UIC member number */ unsigned char fh1$b_uicgroup; /* UIC group number */ } fh1$r_fileowner_fields; } fh1$r_fileowner_overlay; union { unsigned short fh1$w_fileprot; /* file protection */ struct { unsigned fh1$v_syspro : 4; /* system protection */ unsigned fh1$v_ownpro : 4; /* owner protection */ unsigned fh1$v_grouppro : 4; /* group protection */ unsigned fh1$v_worldpro : 4; /* world protection */ } fh1$r_fileprot_bits; } fh1$r_fileprot_overlay; union { unsigned short fh1$w_filechar; /* file characteristics */ struct { union { unsigned char fh1$b_userchar; /* user controlled characteristics */ struct { unsigned fh1$v_wascontig : 1; /* file was (and should be) contiguous */ unsigned fh1$v_nobackup : 1; /* file is not to be backed up */ unsigned : 1; /* reserved */ unsigned fh1$v_readcheck : 1; /* verify all read operations */ unsigned fh1$v_writcheck : 1; /* verify all write operations */ unsigned fh1$v_contigb : 1; /* keep file as contiguous as possible */ unsigned fh1$v_locked : 1; /* file is deaccess locked */ unsigned fh1$v_contig : 1; /* file is contiguous */ } fh1$r_userchar_bits; } fh1$r_userchar_overlay; union { unsigned char fh1$b_syschar; /* system controlled characteristics */ struct { unsigned : 4; /* reserved */ unsigned fh1$v_spool : 1; /* intermediate spool file */ unsigned : 1; /* reserved */ unsigned fh1$v_badblock : 1; /* file contains bad blocks */ unsigned fh1$v_markdel : 1; /* file is marked for delete */ } fh1$r_syschar_bits; } fh1$r_syschar_overlay; } fh1$r_filechar_fields; } fh1$r_filechar_overlay; unsigned short fh1$w_recattr[16]; /* file record attributes */ unsigned short fh1def$$w_fill[232]; /* rest of file header */ unsigned short fh1$w_checksum; /* file header checksum */ }; #endif /*_FH1DEF_H*/