ok here's the problem i have this swap function that was created for a previous program, and i want to use it for a sort routine (bubble)

struct students temp;

strcpy(temp.name, s1->name);
temp.test1 = s1->test1;
temp.test2 = s1->test2;


strcpy(s1->name, s2->name);
s1->test1 = s2->test1;
s1->test2 = s2->test2;


strcpy(s2->name, temp.name);
s2->test1 = temp.test1;
s2->test2 = temp.test2;
}

so the question is how do i go about passing elements of a structure(a string) from the sort funtion, into the swap fuction.

heres the bubble sort so far

void sort_make(struct cars *inven, int number){
int i, j;
for(j = number; j > number ; j--){

for(i = 0; i < j; i++){

if(inven[i].make > inven[i+1].make)
swap(&inven[i].make, &inven[i+1].make);
}
}

}

-ManicC-