Lines Matching defs:fp

27 **	stdio. fp->f_cookie is the FILE* of stdio. The cookie may be
29 ** When binding late (when fp->f_cookie==NULL) then the value of
30 ** fp->f_ival is used (0, 1 or 2) to map to stdio's stdin, stdout or
38 ** fp -- file pointer assign for this open
50 sm_stdioopen(fp, info, flags, rpool)
51 SM_FILE_T *fp;
98 fp->f_cookie = s;
106 ** fp - the file pointer to get the cookie assigned
113 setup(fp)
114 SM_FILE_T *fp;
116 if (fp->f_cookie == NULL)
118 switch (fp->f_ival)
121 fp->f_cookie = stdin;
124 fp->f_cookie = stdout;
127 fp->f_cookie = stderr;
130 sm_abort("fp->f_ival=%d: out of range (0...2)", fp->f_ival);
140 ** fp -- the file pointer
149 sm_stdioread(fp, buf, n)
150 SM_FILE_T *fp;
156 if (fp->f_cookie == NULL)
157 setup(fp);
158 s = fp->f_cookie;
166 ** fp -- the file pointer
175 sm_stdiowrite(fp, buf, n)
176 SM_FILE_T *fp;
182 if (fp->f_cookie == NULL)
183 setup(fp);
184 s = fp->f_cookie;
192 ** fp -- the file pointer
201 sm_stdioseek(fp, offset, whence)
202 SM_FILE_T *fp;
208 if (fp->f_cookie == NULL)
209 setup(fp);
210 s = fp->f_cookie;
218 ** fp -- close file pointer
225 sm_stdioclose(fp)
226 SM_FILE_T *fp;
230 if (fp->f_cookie == NULL)
231 setup(fp);
232 s = fp->f_cookie;
240 ** fp -- the file pointer
251 sm_stdiosetinfo(fp, what, valp)
252 SM_FILE_T *fp;
269 ** fp -- the file pointer
280 sm_stdiogetinfo(fp, what, valp)
281 SM_FILE_T *fp;
292 if (fp->f_cookie == NULL)
293 setup(fp);
294 fd = fileno((FILE *) fp->f_cookie);
332 SM_FILE_T *fp;
359 fp = sm_fp(SmFtRealStdio, ioflags, NULL);
360 fp->f_file = fd;
361 fp->f_cookie = stream;
362 return fp;