1: #include "../h/rt.h" 2: 3: /* 4: * deffile - if dp is null, default to def; otherwise, make sure it's a file. 5: */ 6: 7: deffile(dp, def) 8: struct descrip *dp, *def; 9: { 10: DeRef(*dp) 11: if (NULLDESC(*dp)) { 12: *dp = *def; 13: return 1; 14: } 15: if (QUAL(*dp) || TYPE(*dp) != T_FILE) 16: runerr(105, dp); 17: return 0; 18: }