openbsd-ports/www/sarg/patches/patch-index_c
aanriot 87ee110593 - use log files paths accordingly to www/squid.
- fix SYSCONFDIR and other substitutions.

from maintainer Douglas Santos with a few changes;
inputs and ok alek@
2006-01-28 21:22:07 +00:00

15 lines
639 B
Plaintext

--- index.c.orig Tue Nov 29 17:39:45 2005
+++ index.c Thu Jan 26 21:31:44 2006
@@ -369,9 +369,9 @@ void make_index()
unlink(wdir_tmp2);
} else {
if(strcmp(IndexSortOrder,"A") == 0)
- sprintf(warea,"sort -t';' +6.5n +6.2M +6.0n '%s' -o '%s'", wdir_tmp, wdir_tmp2);
+ sprintf(warea,"sort -t';' -k 7,7 %s -o %s", wdir_tmp, wdir_tmp2);
else
- sprintf(warea,"sort -t';' +6.5nr +6.2Mr +6.0nr '%s' -o '%s'", wdir_tmp, wdir_tmp2);
+ sprintf(warea,"sort -t';' -r -k 7,7 %s -o %s", wdir_tmp, wdir_tmp2);
system(warea);
unlink(wdir_tmp);
if((fp_ou=fopen(wdir,"w"))==NULL) {