×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Nov 2004
    Location
    Singapore
    Posts
    4

    Urgent: Socket related Error

    Hello Developers,

    I am Sending a binary data through a perticular Socket(remote machine). I am sending a 2 byte integer and then 4 byte integer

    as data. To retrive data on the device I am using this piece of code.

    // this part of code for 16 bit value retrival
    const unsigned short* val16 = reinterpret_cast<const unsigned short*>(&data()[m_pos]);

    // this part of code for 32 bit value retrival
    const unsigned long* val32 = reinterpret_cast<const unsigned long*>(&data()[m_pos]);

    The problem here is that I am getting a KernExe-3 on the device and the device crashes after the above code executes.
    I am guessing that this problem is related to ARM processor's word alignment.

    This code work perfectly fine on the Emulator but does not do the same on the device.

    An URGENT solution or comments on this problem will be helpful.


    Jinesh/Parag.

  2. #2
    Registered User
    Join Date
    Feb 2005
    Posts
    21
    It would be quite useful to see more of your source code.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •