Lines Matching +full:release +full:- +full:linux
8 <<funopen>>, <<fropen>>, <<fwopen>>---open a stream with custom callbacks
35 <[readfn]> should return -1 on failure, or else the number of bytes
41 <[writefn]> should return -1 on failure, or else the number of bytes
47 <[seekfn]> should return (fpos_t)-1 on failure, or else the current
54 <[closefn]> should return -1 on failure, or 0 on success. It is
78 It is not portable. See also the <<fopencookie>> interface from Linux.
116 if ((result = c->readfn (c->cookie, buf, n)) < 0 && errno) in funreader()
130 if ((result = c->writefn (c->cookie, buf, n)) < 0 && errno) in funwriter()
145 if ((result = c->seekfn (c->cookie, (fpos_t) off, whence)) < 0 && errno) in funseeker()
150 if ((result = c->seekfn (c->cookie, (_fpos64_t) off, whence)) < 0 && errno) in funseeker()
155 result = -1; in funseeker()
171 if ((result = c->seekfn (c->cookie, off, whence)) < 0 && errno) in funseeker64()
183 if (c->closefn) in funcloser()
186 if ((result = c->closefn (c->cookie)) < 0 && errno) in funcloser()
214 fp->_flags = 0; /* release */ in funopen()
216 __lock_close_recursive (fp->_lock); in funopen()
223 fp->_file = -1; in funopen()
224 c->cookie = (void *) cookie; /* cast away const */ in funopen()
225 fp->_cookie = c; in funopen()
228 c->readfn = readfn; in funopen()
229 fp->_read = funreader; in funopen()
232 fp->_flags = __SRW; in funopen()
233 c->writefn = writefn; in funopen()
234 fp->_write = funwriter; in funopen()
238 fp->_flags = __SRD; in funopen()
239 c->writefn = NULL; in funopen()
240 fp->_write = NULL; in funopen()
245 fp->_flags = __SWR; in funopen()
246 c->writefn = writefn; in funopen()
247 fp->_write = funwriter; in funopen()
248 c->readfn = NULL; in funopen()
249 fp->_read = NULL; in funopen()
251 c->seekfn = seekfn; in funopen()
252 fp->_seek = seekfn ? funseeker : NULL; in funopen()
254 fp->_seek64 = seekfn ? funseeker64 : NULL; in funopen()
255 fp->_flags |= __SL64; in funopen()
257 c->closefn = closefn; in funopen()
258 fp->_close = funcloser; in funopen()