diff options
author | Elliott Hughes <enh@google.com> | 2015-01-21 16:19:07 -0800 |
---|---|---|
committer | Elliott Hughes <enh@google.com> | 2015-01-21 17:09:58 -0800 |
commit | 8b5df3920f2843c9cdf04160517c1e8b77c992f5 (patch) | |
tree | a0a678ee8f107e5c25f937f444a970a0539d2af7 /libc/stdio/fileext.h | |
parent | 2a8c929aaf8d34d2b6e89ed9c8b6da163316143e (diff) | |
download | android_bionic-8b5df3920f2843c9cdf04160517c1e8b77c992f5.tar.gz android_bionic-8b5df3920f2843c9cdf04160517c1e8b77c992f5.tar.bz2 android_bionic-8b5df3920f2843c9cdf04160517c1e8b77c992f5.zip |
Turn on -Wold-style-cast and fix the errors.
A couple of dodgy cases where we cast away const, but otherwise pretty boring.
Change-Id: Ibc39ebd525377792b5911464be842121c20f03b9
Diffstat (limited to 'libc/stdio/fileext.h')
-rw-r--r-- | libc/stdio/fileext.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libc/stdio/fileext.h b/libc/stdio/fileext.h index 75230cda1..209815aee 100644 --- a/libc/stdio/fileext.h +++ b/libc/stdio/fileext.h @@ -47,7 +47,12 @@ struct __sfileext { bool _stdio_handles_locking; /* __fsetlocking support */ }; +#if defined(__cplusplus) +#define _EXT(fp) reinterpret_cast<__sfileext*>((fp)->_ext._base) +#else #define _EXT(fp) ((struct __sfileext *)((fp)->_ext._base)) +#endif + #define _UB(fp) _EXT(fp)->_ub #define _FLOCK(fp) _EXT(fp)->_lock |