This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Functionality fails due to data alignment issue.



I am noticing an issue where my codes functionality fails if I have the variables in the order below.


int x;
short y[18];
int z, a, b;

rearranging them as 

short y[18];

int x;

int z, a, b;

restores the pass functionality.

This little snippet is a part of a 150 file project.

Any suggestions of why this might be occuring ?