summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdio/ungetc.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/stdio/ungetc.c')
-rw-r--r--lib/libc/stdio/ungetc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/stdio/ungetc.c b/lib/libc/stdio/ungetc.c
index 872abad..f70fb42 100644
--- a/lib/libc/stdio/ungetc.c
+++ b/lib/libc/stdio/ungetc.c
@@ -164,7 +164,7 @@ __ungetc(int c, FILE *fp)
* Initially, we will use the `reserve' buffer.
*/
fp->_ur = fp->_r;
- fp->_up = fp->_p;
+ fp->_extra->_up = fp->_p;
fp->_ub._base = fp->_ubuf;
fp->_ub._size = sizeof(fp->_ubuf);
fp->_ubuf[sizeof(fp->_ubuf) - 1] = c;
OpenPOWER on IntegriCloud