Bug #1454 ยป a.patch
src/filebundle.c | ||
---|---|---|
215 | 215 |
/* Bundle */ |
216 | 216 |
#if ENABLE_BUNDLE |
217 | 217 |
char *tmp1 = strdup(path); |
218 |
char *tmp2 = strtok(tmp1, "/"); |
|
218 |
char *tmp2; |
|
219 |
char *tmp3 = strtok_r(tmp1, "/", &tmp2); |
|
219 | 220 |
filebundle_entry_t *fb = filebundle_root; |
220 |
while (fb && tmp2) {
|
|
221 |
if (fb->type == FB_DIR && !strcmp(fb->name, tmp2)) {
|
|
222 |
tmp2 = strtok(NULL, "/");
|
|
223 |
if (tmp2) fb = fb->d.child;
|
|
221 |
while (fb && tmp3) {
|
|
222 |
if (fb->type == FB_DIR && !strcmp(fb->name, tmp3)) {
|
|
223 |
tmp3 = strtok_r(NULL, "/", &tmp2);
|
|
224 |
if (tmp3) fb = fb->d.child;
|
|
224 | 225 |
} else { |
225 | 226 |
fb = fb->next; |
226 | 227 |
} |
227 |
- |