mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 00:41:02 +00:00
Bugfix decoding
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@22284 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
d98714e355
commit
fd8bfa11d5
2 changed files with 4 additions and 2 deletions
|
@ -4,6 +4,8 @@
|
|||
When calculating info about a structure, make sure its alignment is
|
||||
that of its most strictly aligned field and make sure its size is a
|
||||
multiple of its alignment.
|
||||
* Source/NSData.m: ([initWithCoder:]) Fix bug decoding unsigned long
|
||||
into unsigned int variable ... breaks on amd64
|
||||
|
||||
2006-01-10 Richard Frith-Macdonald <rfm@gnu.org>
|
||||
|
||||
|
|
|
@ -1770,7 +1770,7 @@ failure:
|
|||
unsigned length = [self length];
|
||||
void *bytes = [self mutableBytes];
|
||||
|
||||
[aCoder encodeValueOfObjCType: @encode(unsigned long)
|
||||
[aCoder encodeValueOfObjCType: @encode(unsigned int)
|
||||
at: &length];
|
||||
if (length)
|
||||
{
|
||||
|
@ -1802,7 +1802,7 @@ failure:
|
|||
zone = [self zone];
|
||||
#endif
|
||||
|
||||
[aCoder decodeValueOfObjCType: @encode(unsigned long) at: &l];
|
||||
[aCoder decodeValueOfObjCType: @encode(unsigned int) at: &l];
|
||||
if (l)
|
||||
{
|
||||
void *b = NSZoneMalloc(zone, l);
|
||||
|
|
Loading…
Reference in a new issue