zzip_tell(3)

πŸ“¦
version 0.13.78 Β· 4 versions
, in centos-stream 10, debian trixie, fedora 43, fedora 44, opensuse-leap 16.0, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– zzip_tell(3) β€” bestie edition πŸ’–

okay so this is a page from the zziplib Function List manual, and today we're talking about the tell girlies: zzip_tell and zzip_tell32. no cap, they're literally just here to tell you where you are. πŸŽ€


✨ NAME ✨

zzip_tell, zzip_tell32 β€” tell. that's it. that's the vibe. πŸ’…


✨ SYNOPSIS ✨

#include <zzip/lib.h>

zzip_off_t
zzip_tell(ZZIP_FILE* fp)

long
zzip_tell32(ZZIP_FILE* fp)

ok so you pull in the header, then you've got two lil functions to choose from β€” the big one and the small one. slay. πŸ¦‹


✨ DESCRIPTION ✨

so zzip_tell is the moment where it goes tell(2) and reports the current position inside a real/zipped file. main character behaviour honestly.

it hands back the current offset within that real/zipped file, and if we're in the zipped-file situation, that offset is measured in uncompressed bytes. yes bestie, uncompressed β€” we're counting the vibes after decompression, not the squished bytes on disk. πŸ’–

now here's the tea πŸ“: if the file-handle is wrapping a file that's stat-able, it will lowkey just do a normal tell(2)-call like nothing happened. but if it's not stat-able, then the offset gets calculated from the amount of data left plus the total uncompressed size. either way you get your number, the path there just depends. ✨

and zzip_tell32? she's provided for the users who can't use any largefile-mode. a whole function just for y'all. iconic, honestly. πŸ‘‘

ngl if you're on a largefile setup, zzip_tell is your girl. if you're not, zzip_tell32 has you. pick your fighter. 🫢

✨ AUTHOR ✨

  • Guido Draheim <guidod@gmx.de>
  • Tomi Ollila <Tomi.Ollila@iki.fi>

the two legends who made this happen, periodt. πŸ˜­πŸ’œ


Copyright (c) Guido Draheim, use under copyleft (LGPL,MPL)


ok that's the whole page bestie, go forth and tell(2) responsibly. ✨🌸

this was zzip_tell(3) from zziplib, version 0.13.78 β€” mwah, love u, bye πŸ’…πŸŽ€πŸ¦‹