From 68cdc08aec92abf91448a542e06fabbedbb583bf Mon Sep 17 00:00:00 2001 From: root Date: Fri, 31 Aug 2012 00:04:43 +0000 Subject: Fri Aug 31 00:04:43 UTC 2012 --- community/fortune-mod/01_all_fortune_all-fix.patch | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 community/fortune-mod/01_all_fortune_all-fix.patch (limited to 'community/fortune-mod/01_all_fortune_all-fix.patch') diff --git a/community/fortune-mod/01_all_fortune_all-fix.patch b/community/fortune-mod/01_all_fortune_all-fix.patch new file mode 100644 index 000000000..b4175ac81 --- /dev/null +++ b/community/fortune-mod/01_all_fortune_all-fix.patch @@ -0,0 +1,21 @@ +--- fortune/fortune.c.old 2006-03-11 15:33:14.000000000 +0100 ++++ fortune/fortune.c 2006-03-11 15:43:16.000000000 +0100 +@@ -974,7 +974,7 @@ + if (!ret) + ret=add_file(percent, fullpathname, NULL, &File_list, + &File_tail, NULL); +- if ( (!ret && fullpathname != locpathname) || strcmp(sp, "all") == 0 ) ++ if (!ret && strncmp(fullpathname, locpathname, sizeof(fullpathname))) + ret=add_file(percent, locpathname, NULL, &File_list, + &File_tail, NULL); + +@@ -985,7 +985,8 @@ + } + if (!ret) + return FALSE; +- ++ if (strncmp(fullpathname, locpathname, sizeof(fullpathname)) && strcmp(sp, "all") == 0) ++ add_file(percent, locpathname, NULL, &File_list, &File_tail, NULL); + } + else + if (!add_file(percent, fullpathname, NULL, &File_list, -- cgit v1.2.3-54-g00ecf