Aaah okey I didn't get what you were trying to say, ok will try that out to see if it works... thanks
Will come with the results soon
EDIT:
Ok changed:
Code:
table tmp;
tmp.cell[j] = t->cell[j];
t->cell[j] = t->cell[j+1];
t->cell[j+1] = tmp.cell[j];
to:
Code:
char **tmp;
tmp = t->cell[j];
t->cell[j] = t->cell[j+1];
t->cell[j+1] = tmp;
Is this what you meant? BTW and very important I realised how stupid I am just when I read the while loop and found it was wrong, order = 1; should be out of the for loop not inside of it... changing this and doing what tabstop suggested seems to solve the segmentation fault... just tested once so I'll keep testing and will come back u.u
EDIT 2:
Tested various times and it works as expected
So if the replacement is what you meant tell me please so I'm confident enough that this is alright and solved ok?
p.s.: I feel sooo stupid lol... at least I don't need now a table tmp...