Home
last modified time | relevance | path

Searched refs:_p (Results 1 – 25 of 31) sorted by relevance

12

/bionic/libc/upstream-openbsd/lib/libc/stdio/
Dfgetln.c79 if ((p = memchr((void *)fp->_p, '\n', fp->_r)) != NULL) { in fgetln()
86 ret = (char *)fp->_p; in fgetln()
87 *lenp = len = p - fp->_p; in fgetln()
90 fp->_p = p; in fgetln()
115 (void)memcpy((void *)(fp->_lb._base + off), (void *)fp->_p, in fgetln()
120 if ((p = memchr((void *)fp->_p, '\n', fp->_r)) == NULL) in fgetln()
125 diff = p - fp->_p; in fgetln()
129 (void)memcpy((void *)(fp->_lb._base + off), (void *)fp->_p, in fgetln()
132 fp->_p = p; in fgetln()
Dungetc.c63 fp->_p = p; in __submore()
72 fp->_p = p + i; in __submore()
114 *--fp->_p = c; in ungetc()
126 if (fp->_bf._base != NULL && fp->_p > fp->_bf._base && in ungetc()
127 fp->_p[-1] == c) { in ungetc()
128 fp->_p--; in ungetc()
137 fp->_up = fp->_p; in ungetc()
141 fp->_p = &fp->_ubuf[sizeof(fp->_ubuf) - 1]; in ungetc()
Dfvwrite.c66 #define COPY(n) (void)memcpy((void *)fp->_p, (void *)p, (size_t)(n)) in __sfvwrite()
107 size_t blen = fp->_p - fp->_bf._base; in __sfvwrite()
122 fp->_p = _base + blen; in __sfvwrite()
130 fp->_p += w; in __sfvwrite()
132 } else if (fp->_p > fp->_bf._base && len > w) { in __sfvwrite()
136 fp->_p += w; in __sfvwrite()
149 fp->_p += w; in __sfvwrite()
173 if (fp->_p > fp->_bf._base && s > w) { in __sfvwrite()
176 fp->_p += w; in __sfvwrite()
187 fp->_p += w; in __sfvwrite()
Dvfscanf.c134 isspace(*fp->_p)) in __svfscanf()
135 nread++, fp->_r--, fp->_p++; in __svfscanf()
152 if (*fp->_p != c) in __svfscanf()
154 fp->_r--, fp->_p++; in __svfscanf()
318 while (isspace(*fp->_p)) { in __svfscanf()
321 fp->_p++; in __svfscanf()
353 buf[n++] = *fp->_p; in __svfscanf()
354 fp->_p++; in __svfscanf()
389 fp->_p += n; in __svfscanf()
398 fp->_p += width; in __svfscanf()
[all …]
Dfgets.c76 p = fp->_p; in fgets()
90 fp->_p = t; in fgets()
97 fp->_p += len; in fgets()
Dgetdelim.c76 p = memchr(fp->_p, sep, (size_t)fp->_r); in getdelim()
80 len = (p - fp->_p) + 1; in getdelim()
113 (void)memcpy((*buf + off), fp->_p, len); in getdelim()
116 fp->_p += (int)len; in getdelim()
Dvsprintf.c54 f._bf._base = f._p = (unsigned char *)str; in vsprintf()
57 *f._p = '\0'; in vsprintf()
Dwbuf.c72 n = fp->_p - fp->_bf._base; in __swbuf()
79 *fp->_p++ = c; in __swbuf()
Dvsnprintf.c59 f._bf._base = f._p = (unsigned char *)str; in vsnprintf()
62 *f._p = '\0'; in vsnprintf()
Dmakebuf.c57 fp->_bf._base = fp->_p = fp->_nbuf; in __smakebuf()
64 fp->_bf._base = fp->_p = fp->_nbuf; in __smakebuf()
69 fp->_bf._base = fp->_p = p; in __smakebuf()
Dvasprintf.c36 f._bf._base = f._p = malloc(128); in vasprintf()
43 *f._p = '\0'; in vasprintf()
Dasprintf.c38 f._bf._base = f._p = malloc(128); in asprintf()
47 *f._p = '\0'; in asprintf()
Drget.c48 return (*fp->_p++); in __srget()
Dfflush.c69 n = fp->_p - p; /* write this much */ in __sflush()
75 fp->_p = p; in __sflush()
Dvswprintf.c58 f._bf._base = f._p = malloc(128); in vswprintf()
76 *f._p = '\0'; in vswprintf()
Dfpurge.c56 fp->_p = fp->_bf._base; in fpurge()
Dvsscanf.c54 f._bf._base = f._p = (unsigned char *)str; in vsscanf()
Dsetvbuf.c109 fp->_bf._base = fp->_p = fp->_nbuf; in setvbuf()
139 fp->_bf._base = fp->_p = (unsigned char *)buf; in setvbuf()
Dsscanf.c58 f._bf._base = f._p = (unsigned char *)str; in sscanf()
Dvdprintf.c60 f._p = buf; in vdprintf()
/bionic/libc/stdio/
Dlocal.h60 unsigned char *_p; /* current position in (some) buffer */ member
255 #define __sgetc(p) (--(p)->_r < 0 ? __srget(p) : (int)(*(p)->_p++))
256 static __inline int __sputc(int _c, FILE* _p) { in __sputc() argument
257 if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n')) { in __sputc()
258 return (*_p->_p++ = _c); in __sputc()
260 return (__swbuf(_c, _p)); in __sputc()
Dsprintf.c57 f._bf._base = f._p = (unsigned char *)str; in sprintf()
62 *f._p = '\0'; in sprintf()
Dsnprintf.c61 f._bf._base = f._p = (unsigned char *)str; in snprintf()
66 *f._p = '\0'; in snprintf()
Drefill.c88 fp->_p = fp->_up; in __srefill()
112 fp->_p = fp->_bf._base; in __srefill()
113 fp->_r = (*fp->_read)(fp->_cookie, (char *)fp->_p, fp->_bf._size); in __srefill()
Dfread.c87 memcpy(dst, fp->_p, buffered_bytes); in fread()
88 fp->_p += buffered_bytes; in fread()

12