diff options
Diffstat (limited to 'lib/tar/checksum.c')
-rw-r--r-- | lib/tar/checksum.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tar/checksum.c b/lib/tar/checksum.c index 925f942..a2a101a 100644 --- a/lib/tar/checksum.c +++ b/lib/tar/checksum.c @@ -11,7 +11,7 @@ void update_checksum(tar_header_t *hdr) for (i = 0; i < sizeof(*hdr); ++i) chksum += ((unsigned char *)hdr)[i]; - write_octal(hdr->chksum, chksum, 6); + sprintf(hdr->chksum, "%06o", chksum); hdr->chksum[6] = '\0'; hdr->chksum[7] = ' '; } |