BLIP/BLIPReader.m
changeset 8 6f539dd9921c
parent 2 9fdd8dba529c
child 11 29e8b03c05d4
     1.1 --- a/BLIP/BLIPReader.m	Sat May 24 17:25:06 2008 -0700
     1.2 +++ b/BLIP/BLIPReader.m	Thu May 29 16:40:36 2008 -0700
     1.3 @@ -63,10 +63,10 @@
     1.4  - (NSString*) _validateHeader
     1.5  {
     1.6      // Convert header to native byte order:
     1.7 -    _curHeader.magic = EndianU32_BtoN(_curHeader.magic);
     1.8 -    _curHeader.number= EndianU32_BtoN(_curHeader.number);
     1.9 -    _curHeader.flags = EndianU16_BtoN(_curHeader.flags);
    1.10 -    _curHeader.size  = EndianU16_BtoN(_curHeader.size);
    1.11 +    _curHeader.magic = NSSwapBigIntToHost(_curHeader.magic);
    1.12 +    _curHeader.number= NSSwapBigIntToHost(_curHeader.number);
    1.13 +    _curHeader.flags = NSSwapBigShortToHost(_curHeader.flags);
    1.14 +    _curHeader.size  = NSSwapBigShortToHost(_curHeader.size);
    1.15      
    1.16      if( _curHeader.magic != kBLIPFrameHeaderMagicNumber )
    1.17          return $sprintf(@"Incorrect magic number (%08X not %08X)",