From: Mark Wooding Date: Tue, 13 Nov 2012 23:39:45 +0000 (+0000) Subject: space.c: Strip `typedef' from `buf'; now it's just a struct. X-Git-Tag: 1.2.8.2~2 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/misc/commitdiff_plain/eb5e380cfc938d0a2c1951624072c2445a9e325c?hp=71fbd124150265803c825ed94a47d59cac0c525d space.c: Strip `typedef' from `buf'; now it's just a struct. --- diff --git a/space.c b/space.c index 5a6a0de..73fb3a7 100644 --- a/space.c +++ b/space.c @@ -95,16 +95,16 @@ fail_0: return (0); } -typedef struct buf { +struct buf { char *b; size_t n; size_t sz; -} buf; +}; #define BUF_INIT { 0, 0, 0 } -static void reset(buf *b) { b->n = 0; } +static void reset(struct buf *b) { b->n = 0; } -static int put(buf *b, int ch) +static int put(struct buf *b, int ch) { size_t w; @@ -130,7 +130,7 @@ static int put(buf *b, int ch) static int space(const char *name) { - static buf b = BUF_INIT; + static struct buf b = BUF_INIT; FILE *fin, *fout = stdout; char *newname = 0, *oldname = 0; int rc = TROUBLE, status = OK;