Searched defs:f1 (Results 1 - 21 of 21) sorted by relevance

/ast/src/cmd/tests/sfio/
H A Dtswap.c24 Sfio_t* f1; local
28 if(!(f1 = sfopen(NIL(Sfio_t*), tstfile("sf", 0),"w+")) )
30 if(sfwrite(f1,"0123456789\n",11) != 11)
34 if(sfswap(f1,sfstdin) != sfstdin)
42 if(!(f1 = sfswap(sfstdin,NIL(Sfio_t*))) )
44 if(!sfstack(sfstdout,f1) )
45 terror("Failed stacking f1");
50 if(sfswap(f1,f2) != NIL(Sfio_t*) )
H A Dtappend.c24 Sfio_t *f1, *f2; local
30 if(!(f1 = sfopen(NIL(Sfio_t*), tstfile("sf", 0), "w")) )
31 terror("Can't open f1");
32 if(!(f1 = sfopen(f1, tstfile("sf", 0), "a+")) )
33 terror("Can't open f1");
38 if(sfwrite(f1,"012345678\n",10) != 10 || sfsync(f1) < 0)
39 terror("Writing to f1");
40 if((p = sftell(f1)) !
[all...]
H A Dtpool.c44 Sfio_t *f, *f1, *f2, *f3, *f4; local
46 if(!(f1 = sfopen((Sfio_t*)0,tstfile("sf", 0),"w+")) ||
53 sfungetc(f1,'a');
55 sfpool(f1,f4,0);
56 sfungetc(f1,'a');
57 sfpool(f1,NIL(Sfio_t*),0);
67 if(sfputr(f1,os,-1) < 0)
69 sfseek(f1,(Sfoff_t)0,0);
71 { if(!(s = sfgetr(f1,'\n',0)) || (n = sfvalue(f1)) !
[all...]
H A Dtstack.c82 Sfio_t *f1, *f2, *f3, *f; local
87 if(!(f1 = sfopen(NIL(Sfio_t*), tstfile("sf", 0),"w+")) )
92 sfdisc(f1,&Disc);
94 sfstack(f1,f2);
95 if((n = sfgetc(f1)) >= 0 || !sfeof(f1))
97 if(sfstacked(f1))
99 Fclose = f1;
100 if(sfclose(f1) < 0)
101 terror("Can't close f1");
[all...]
H A Dtsync.c95 Sfio_t *f, *f1, *f2; local
127 if(!(f1 = sfopen(NIL(Sfio_t*), tstfile("sf", 0), "w")) )
132 sfset(f1,SF_IOCHECK,1);
133 sfdisc(f1,&Disc);
134 sfsetbuf(f1,NIL(char*),4);
139 sfputc(f1,'1');
140 sfputc(f1,'2');
141 sfputc(f1,'3');
142 sfputc(f1,'4');
143 sfputc(f1,'
[all...]
/ast/src/cmd/ksh93/tests/
H A Dtreemove.sh72 function f1 function
96 f1 tree1
H A Dcomvar.sh499 function f1 function
510 f1 tree
H A Dtypes.sh259 function f1 function
266 function f { f1 _ ;}
H A Dfunctions.sh1152 function f1 { print -n ${.sh.fun}; set -o | grep xtrace;} function
1154 f1
/ast/src/lib/libast/sfio/
H A Dsfstack.c30 #define STKMTXLOCK(f1,f2) \
31 { if(f1) SFMTXLOCK(f1); \
34 #define STKMTXRETURN(f1,f2,rv) \
35 { if(f1) SFMTXUNLOCK(f1); \
41 Sfio_t* sfstack(Sfio_t* f1, Sfio_t* f2) argument
43 Sfio_t* sfstack(f1,f2)
44 Sfio_t* f1; /* base of stack */
53 STKMTXLOCK(f1,f
[all...]
H A Dsfswap.c33 Sfio_t* sfswap(reg Sfio_t* f1, reg Sfio_t* f2) argument
35 Sfio_t* sfswap(f1,f2)
36 reg Sfio_t* f1;
43 if(!f1 || (f1->mode&SF_AVAIL) || (SFFROZEN(f1) && (f1->mode&SF_PUSH)) )
47 if(f1 == f2)
50 f1mode = f1->mode;
51 SFLOCK(f1,
[all...]
/ast/src/lib/libcmd/
H A Dcomm.c152 Sfio_t *f1, *f2; local
183 f1 = sfstdin;
184 else if(!(f1 = sfopen(NiL, cp,"r")))
193 if(comm(f1,f2,sfstdout,mode) < 0)
196 else if(f1==sfstdin || f2==sfstdin)
198 if(f1!=sfstdin)
199 sfclose(f1);
H A Dcksum.c424 order(FTSENT* const* f1, FTSENT* const* f2) argument
426 return strcoll((*f1)->fts_name, (*f2)->fts_name);
H A Dcmp.c145 cmp(const char* file1, Sfio_t* f1, const char* file2, Sfio_t* f2, int flags, Sfoff_t count, Sfoff_t differences) argument
165 if (!(p1 = (unsigned char*)sfreserve(f1, SF_UNBOUND, 0)) || (c1 = sfvalue(f1)) <= 0)
258 Sfio_t* f1 = 0; local
317 f1 = sfstdin;
318 else if (!(f1 = sfopen(NiL, file1, "r")))
355 if (o1 && sfseek(f1, o1, SEEK_SET) != o1)
369 if (fstat(sffileno(f1), &s1))
376 n = ((flags & CMP_SILENT) && S_ISREG(s1.st_mode) && S_ISREG(s2.st_mode) && (s1.st_size - o1) != (s2.st_size - o2)) ? 1 : cmp(file1, f1, file2, f2, flags, count, differences);
378 if (f1
[all...]
/ast/src/cmd/cs/
H A Dcs.c171 order(register Ftw_t* f1, register Ftw_t* f2) argument
173 return f1->level == 3 ? strcoll(f1->name, f2->name) : 0;
/ast/src/cmd/tw/
H A Dtw.c601 order(register Ftw_t* f1, register Ftw_t* f2) argument
639 v = icase ? strcasecmp(f1->name, f2->name) : strcoll(f1->name, f2->name);
642 n1 = getnum(x->data.variable.symbol, f1);
666 message((-2, "order(%s,%s) = %d [n1=%ld n2=%ld]", f1->name, f2->name, v, n1, n2));
H A Dfind.c1668 register const FTSENT* f1 = *p1; local
1670 register State_t* state = f1->fts->fts_handle;
1678 n2 = f1->fts_statp->st_atime;
1682 n2 = f1->fts_statp->st_ctime;
1686 n2 = f1->fts_statp->st_mtime;
1690 n2 = f1->fts_statp->st_size;
1698 n = state->icase ? strcasecmp(f1->fts_name, f2->fts_name) : strcoll(f1->fts_name, f2->fts_name);
/ast/src/lib/libast/misc/
H A Dfts.c226 register const FTSENT* f1 = *pf1; local
229 if (f1->statb.st_ino < f2->statb.st_ino)
231 if (f1->statb.st_ino > f2->statb.st_ino)
233 if (f1->statb.st_dev < f2->statb.st_dev)
235 if (f1->statb.st_dev > f2->statb.st_dev)
242 if (f1->statb.st_mtime < f2->statb.st_mtime)
244 if (f1->statb.st_mtime > f2->statb.st_mtime)
/ast/src/lib/libtk/generic/
H A DtkCanvas.c3525 double range, f1, f2;
3529 f1 = 0;
3532 f1 = (screen1 - object1)/range;
3533 if (f1 < 0) {
3534 f1 = 0.0;
3540 if (f2 < f1) {
3541 f2 = f1;
3544 sprintf(string, "%g %g", f1, f2);
3497 double range, f1, f2; local
/ast/src/cmd/std/
H A Dls.c1044 order_none(register Ftw_t* f1, register Ftw_t* f2) argument
1050 order_blocks(register Ftw_t* f1, register Ftw_t* f2) argument
1052 if (f1->statb.st_size < f2->statb.st_size)
1054 if (f1->statb.st_size > f2->statb.st_size)
1060 order_atime(register Ftw_t* f1, register Ftw_t* f2) argument
1065 t1 = tmxgetatime(&f1->statb);
1075 order_ctime(register Ftw_t* f1, register Ftw_t* f2) argument
1080 t1 = tmxgetctime(&f1->statb);
1090 order_mtime(register Ftw_t* f1, register Ftw_t* f2) argument
1095 t1 = tmxgetmtime(&f1
1105 order_extension(register Ftw_t* f1, register Ftw_t* f2) argument
1130 order_version(Ftw_t* f1, Ftw_t* f2) argument
1136 order_name(Ftw_t* f1, Ftw_t* f2) argument
1146 order(register Ftw_t* f1, register Ftw_t* f2) argument
[all...]
/ast/src/cmd/ksh93/sh/
H A Dio.c628 * Given a file descriptor <f1>, move it to a file descriptor number <f2>
630 * The original stream <f1> is closed.
633 int sh_iorenumber(Shell_t *shp, register int f1,register int f2) argument
636 if(f1!=f2)
650 register Sfio_t *spnew = sh_iostream(shp,f1);
651 shp->fdstatus[f2] = (shp->fdstatus[f1]&~IOCLEX);
658 shp->fdstatus[f2] = (shp->fdstatus[f1]&~IOCLEX);
659 if((f2 = sh_fcntl(f1,F_DUPFD, f2)) < 0)
665 shp->sftable[f1] = 0;
666 if(shp->fdstatus[f1]!
[all...]

Completed in 67 milliseconds