• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Different structure sizes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Different structure sizes


  • Subject: Re: Different structure sizes
  • From: Frederick Cheung <email@hidden>
  • Date: Wed, 14 Dec 2005 08:45:14 +0000

On 12/14/05, Jeff Laing <email@hidden> wrote:
> > > The test app was printing 8 and the kext 6 as detailed earlier for
> > > sizeof(PadState). I thought I had stated that earlier.
>
> I've run into this sort of problem before (on another operating system -
> cough) and it came down to the header files you had included.
>
> I will bet London to a brick that you have a different structure packing
> value being left "current" depending on what headers you include, and that
> the fix will be to put the appropriate #pragma (or whatever it is on OSX,
> I'm away from my mac at the moment) to explicitly specify the packing you
> want immediately above your structure.

That's was my initial gut feeling upon seeing the first message, but
PadState contains 8 UInt8, so packing or not there's no way
sizeof(PadState) should be less than 8, unless I am missing something.

Fred

Fred
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Different structure sizes
      • From: Cameron Hayne <email@hidden>
References: 
 >RE: Different structure sizes (From: Jeff Laing <email@hidden>)

  • Prev by Date: Re: Solved: "C" Functions Won't Link Between .mm Files
  • Next by Date: GCC 4 and iostream.h
  • Previous by thread: RE: Different structure sizes
  • Next by thread: Re: Different structure sizes
  • Index(es):
    • Date
    • Thread