sbase

suckless unix tools
git clone git://git.2f30.org/sbase
Log | Files | Refs | README | LICENSE

commit 153b8428b1b0095ca877573e2c310aa4e49ba0f2
parent fb85f99c0a5bb330178d29d582aedc07b1a0f5db
Author: sin <sin@2f30.org>
Date:   Tue, 16 Dec 2014 21:00:19 +0000

Nuke another freelist()

Diffstat:
MTODO | 2+-
Msort.c | 14--------------
2 files changed, 1 insertion(+), 15 deletions(-)

diff --git a/TODO b/TODO @@ -35,7 +35,7 @@ We also need to add support for UTF-8. We have imported libutf from suckless.org. As a first step we should rework existing tools that use wide characters to use the libutf library. -Update manpages to the new style. Look at cmp.1 or at the OpenBSD +Update manpages to the new style. Look at grep.1 or at the OpenBSD manpages for more information. [0] http://landley.net/toybox/roadmap.html diff --git a/sort.c b/sort.c @@ -33,7 +33,6 @@ static struct kdlist *tail = NULL; static void addkeydef(char *, int); static void check(FILE *); -static void freelist(void); static int linecmp(const char **, const char **); static char *skipblank(char *); static int parse_flags(char **, int *, int); @@ -124,7 +123,6 @@ main(int argc, char *argv[]) } } - freelist(); return 0; } @@ -165,18 +163,6 @@ check(FILE *fp) } } -static void -freelist(void) -{ - struct kdlist *node; - struct kdlist *tmp; - - for (node = head; node; node = tmp) { - tmp = node->next; - free(node); - } -} - static int linecmp(const char **a, const char **b) {