Loading src/urlglob.c +24 −22 Original line number Diff line number Diff line Loading @@ -138,7 +138,8 @@ static GlobCode glob_set(URLGlob *glob, char *pattern, /* we never reach this point */ } static GlobCode glob_range(URLGlob *glob, char *pattern, int pos, int *amount) static GlobCode glob_range(URLGlob *glob, char *pattern, size_t pos, int *amount) { /* processes a range expression with the point behind the opening '[' - char range: e.g. "a-z]", "B-Q]" Loading Loading @@ -328,9 +329,10 @@ int glob_url(URLGlob** glob, char* url, int *urlnum, FILE *error) void glob_cleanup(URLGlob* glob) { int i, elem; size_t i; int elem; for (i = glob->size - 1; i >= 0; --i) { for (i = glob->size - 1; i < glob->size; --i) { if (!(i & 1)) { /* even indexes contain literals */ free(glob->literal[i/2]); } Loading @@ -354,7 +356,7 @@ char *glob_next_url(URLGlob *glob) char *buf = glob->glob_buffer; URLPattern *pat; char *lit; int i; size_t i; size_t j; int carry; Loading @@ -365,7 +367,7 @@ char *glob_next_url(URLGlob *glob) /* implement a counter over the index ranges of all patterns, starting with the rightmost pattern */ for (i = glob->size / 2 - 1; carry && i >= 0; --i) { for (i = glob->size / 2 - 1; carry && i < glob->size; --i) { carry = 0; pat = &glob->pattern[i]; switch (pat->type) { Loading Loading
src/urlglob.c +24 −22 Original line number Diff line number Diff line Loading @@ -138,7 +138,8 @@ static GlobCode glob_set(URLGlob *glob, char *pattern, /* we never reach this point */ } static GlobCode glob_range(URLGlob *glob, char *pattern, int pos, int *amount) static GlobCode glob_range(URLGlob *glob, char *pattern, size_t pos, int *amount) { /* processes a range expression with the point behind the opening '[' - char range: e.g. "a-z]", "B-Q]" Loading Loading @@ -328,9 +329,10 @@ int glob_url(URLGlob** glob, char* url, int *urlnum, FILE *error) void glob_cleanup(URLGlob* glob) { int i, elem; size_t i; int elem; for (i = glob->size - 1; i >= 0; --i) { for (i = glob->size - 1; i < glob->size; --i) { if (!(i & 1)) { /* even indexes contain literals */ free(glob->literal[i/2]); } Loading @@ -354,7 +356,7 @@ char *glob_next_url(URLGlob *glob) char *buf = glob->glob_buffer; URLPattern *pat; char *lit; int i; size_t i; size_t j; int carry; Loading @@ -365,7 +367,7 @@ char *glob_next_url(URLGlob *glob) /* implement a counter over the index ranges of all patterns, starting with the rightmost pattern */ for (i = glob->size / 2 - 1; carry && i >= 0; --i) { for (i = glob->size / 2 - 1; carry && i < glob->size; --i) { carry = 0; pat = &glob->pattern[i]; switch (pat->type) { Loading