The patch r172595 was intended for bionic setlocale() which always returns 0. I don't remember I put NULL there initially.
We can simply replace all NULL in r172595 with 0. I attached the updated patch. If it is ok, I will commit the patch into google/gcc-4_6 and google/gcc-4_6-mobile branches. 2011-12-14 H.J. Lu <hongjiu...@intel.com> Jing Yu <jin...@google.com> * config/locale/generic/c_locale.h (__convert_from_v): Replace NULL with 0. * config/locale/generic/c_locale.cc (__convert_to_v): Likewise * config/locale/generic/time_members.cc (_M_put): Likewise Thanks, Jing On Wed, Dec 14, 2011 at 10:12 AM, Diego Novillo <dnovi...@google.com> wrote: > On 11-12-14 13:09 , Paolo Carlini wrote: >> >> Hi, >> >>> Hi, >>> >>> Revision 172595: >>> >>> http://gcc.gnu.org/viewcvs?view=revision&revision=172595 >>> >>> added NULL to config/locale/generic/c_locale.h on >>> google/gcc-4_6-branch. But<cstddef> isn't included, which lead to >>> build failure since NULL isn't defined. This patch >>> includes<cstddef>. OK for google/gcc-4_6-branch? >> >> >> If you are interested in my personal opinion, I have of course >> nothing to do with this branch, I think this code should not simply >> use NULL. After all, its C++, right? ;) > > > Seems reasonable. Jing, 172595 was a patch from you. Would it be the same > if you just used 0 instead of NULL? > > > Diego.
patchnull.diff
Description: Binary data