diff options
Diffstat (limited to 'main/logrotate/qsort.patch')
-rw-r--r-- | main/logrotate/qsort.patch | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/main/logrotate/qsort.patch b/main/logrotate/qsort.patch deleted file mode 100644 index 1e932be192..0000000000 --- a/main/logrotate/qsort.patch +++ /dev/null @@ -1,32 +0,0 @@ ---- ./logrotate.c.orig -+++ ./logrotate.c -@@ -117,11 +117,12 @@ - return 1; - } - --#if defined(HAVE_STRPTIME) && defined(HAVE_QSORT_R) --static int compGlobResult(const void *result1, const void *result2, void *data) { -+#if defined(HAVE_STRPTIME) -+static struct compData qsort_data; -+static int compGlobResult(const void *result1, const void *result2) { - struct tm time; - time_t t1, t2; -- struct compData *d = (struct compData *) data; -+ struct compData *d = &qsort_data; - const char *r1 = *(const char **)(result1); - const char *r2 = *(const char **)(result2); - -@@ -139,10 +140,9 @@ - } - - static void sortGlobResult(glob_t *result, int prefix_len, const char *dformat) { -- struct compData d; -- d.prefix_len = prefix_len; -- d.dformat = dformat; -- qsort_r(result->gl_pathv, result->gl_pathc, sizeof(char *), compGlobResult, &d); -+ qsort_data.prefix_len = prefix_len; -+ qsort_data.dformat = dformat; -+ qsort(result->gl_pathv, result->gl_pathc, sizeof(char *), compGlobResult); - } - #else - static void sortGlobResult(glob_t *result, int prefix_len, const char *dformat) { |