ruby-changes:43159
From: nobu <ko1@a...>
Date: Wed, 1 Jun 2016 02:25:44 +0900 (JST)
Subject: [ruby-changes:43159] nobu:r55233 (trunk): crypt.c: fix size macros
nobu 2016-06-01 02:25:40 +0900 (Wed, 01 Jun 2016) New Revision: 55233 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=55233 Log: crypt.c: fix size macros * missing/crypt.c: fix size macros to use configured values for platforms long is larger than 32bit. [ruby-core:75792] [Bug #12446] Modified files: trunk/ChangeLog trunk/missing/crypt.c Index: missing/crypt.c =================================================================== --- missing/crypt.c (revision 55232) +++ missing/crypt.c (revision 55233) @@ -84,7 +84,7 @@ static char sccsid[] = "@(#)crypt.c 8.1 https://github.com/ruby/ruby/blob/trunk/missing/crypt.c#L84 * define "LONG_IS_32_BITS" only if sizeof(long)==4. * This avoids use of bit fields (your compiler may be sloppy with them). */ -#if !defined(cray) +#if SIZEOF_LONG == 4 #define LONG_IS_32_BITS #endif @@ -92,10 +92,9 @@ static char sccsid[] = "@(#)crypt.c 8.1 https://github.com/ruby/ruby/blob/trunk/missing/crypt.c#L92 * define "B64" to be the declaration for a 64 bit integer. * XXX this feature is currently unused, see "endian" comment below. */ -#if defined(cray) +#if SIZEOF_LONG == 8 #define B64 long -#endif -#if defined(convex) +#elif SIZEOF_LONG_LONG == 8 #define B64 long long #endif Index: ChangeLog =================================================================== --- ChangeLog (revision 55232) +++ ChangeLog (revision 55233) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Wed Jun 1 02:25:38 2016 Nobuyoshi Nakada <nobu@r...> + + * missing/crypt.c: fix size macros to use configured values + for platforms long is larger than 32bit. + [ruby-core:75792] [Bug #12446] + Tue May 31 17:28:46 2016 Nobuyoshi Nakada <nobu@r...> * lib/optparse.rb (OptionParser::Completion.candidate): get rid of -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/