fix for big endian LP64 systems

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@39878 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
rfm 2016-06-19 07:42:36 +00:00
parent 05fd5642ae
commit 019fe5b078
2 changed files with 14 additions and 0 deletions

View file

@ -1,3 +1,11 @@
2016-06-19 Richard Frith-Macdonald <rfm@gnu.org>
* Source/cifframe.m: Use sizeof(NSInteger) as the buffer size for
small scalars if we are on an LP64 machine.
* Source/NSOperation.m: Retain operation while taking it from queue,
releasing after it is finished. Prevent crash if the original owner
of the operation releases it while it's in the queue.
2016-06-17 Richard Frith-Macdonald <rfm@gnu.org>
* Source/GSHTTPURLHandle.m:

View file

@ -45,10 +45,16 @@
#import "GSInvocation.h"
#import "GSPrivate.h"
/* For each architecture, we need to know the native word size to
* which smaller integral types are promoted when they are passed
* as function arguments or return type.
*/
#if defined(ALPHA) || (defined(MIPS) && (_MIPS_SIM == _ABIN32))
typedef long long smallret_t;
#elif defined(__sparc)
typedef NSInteger smallret_t;
#elif defined(__LP64__)
typedef NSInteger smallret_t;
#else
typedef int smallret_t;
#endif