sbase

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

commit 624bf64ac55182655d20c8a21afc6d313927908a
parent 76eb6bdf42a36cc40fb31b2f7a1202a05e482cd9
Author: sin <sin@2f30.org>
Date:   Thu, 23 Apr 2015 15:43:30 +0100

tar: Use more conventional name for iterator

Diffstat:
Mtar.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tar.c b/tar.c @@ -148,7 +148,7 @@ archive(const char *path) struct header *h; struct passwd *pw; struct stat st; - size_t chksum, x; + size_t chksum, i; ssize_t l, r; int fd = -1; @@ -198,8 +198,8 @@ archive(const char *path) } memset(h->chksum, ' ', sizeof(h->chksum)); - for (x = 0, chksum = 0; x < sizeof(*h); x++) - chksum += b[x]; + for (i = 0, chksum = 0; i < sizeof(*h); i++) + chksum += b[i]; putoctal(h->chksum, chksum, sizeof(h->chksum)); ewrite(tarfd, b, BLKSIZ);