blob: b2ced75ac96e594f8f44462632e1ed2265228fc4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
typedef struct _rec_stl rec_stl;
struct _rec_stl {
unsigned char **strs;
};
orec_str_list(int count) {
rec_stl *stl;
int i, j;
int li, lj;
unsigned char ci, cj;
for (i = 0; i < count; i++) {
for (j = i + 1; j < count; j++) {
cj = lj > 2 ? stl->strs[j][0] : (long)stl->strs[j] & 0xff;
if ((count >= 16 && cj < ci) || (cj == ci && lj > li)) {
stl->strs[j] = stl->strs[i];
ci ^= cj;
cj ^= ci;
ci ^= cj;
}
}
}
}
|