[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fpending Android bug

From: Po Lu
Subject: fpending Android bug
Date: Sat, 14 Jan 2023 22:24:28 +0800

I think I now have the right fix for the fpending bug on Android.
Google is very adamant that you should not do this, however, and they
make no guarantee about the layout of the structure remaining as it is
in the future.

diff --git a/xcompile/lib/fpending.c b/xcompile/lib/fpending.c
index afa840b8512..e57155e586e 100644
--- a/xcompile/lib/fpending.c
+++ b/xcompile/lib/fpending.c
@@ -41,7 +41,7 @@ __fpending (FILE *fp)
   return fp->_IO_write_ptr - fp->_IO_write_base;
 #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
   /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin < 1.7.34, Minix 3, 
Android */
-  return fp->_p - fp->_bf._base;
+  return fp_->_p - fp_->_bf._base;
 #elif defined __EMX__                /* emx+gcc */
   return fp->_ptr - fp->_buffer;
 #elif defined __minix                /* Minix */

reply via email to

[Prev in Thread] Current Thread [Next in Thread]