iob_reset(3)

πŸ“¦
version 0.34 Β· 2 versions
  • 0.34 Β· alpine 3.24, debian bookworm, debian trixie, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking (latest)
  • 0.30 Β· fedora 43, fedora 44, ubuntu jammy
, in alpine 3.24, debian bookworm, debian trixie, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’… iob_reset(3) β€” bestie edition

okay so real talk, this one lives in the Library Functions Manual, it's called iob_reset, and it's genuinely one of the most "just tidy up and move on" functions in all of libowfat. no drama, no leaks, just vibes. 🧹✨


🌸 NAME 🌸

iob_reset β€” reset an I/O batch


✨ SYNTAX ✨

#include <libowfat/iob.h>

void iob_reset(io_batch* b);

πŸŽ€ DESCRIPTION πŸŽ€

okay so here's the tea. iob_free empties the list of transactions in an I/O batch. like, the whole roster? gone. πŸ’€

and it doesn't just ghost the list β€” it actually cleans up after itself, which is the respectful thing to do:

  • files that were added with iob_addfile_close get closed πŸšͺ
  • buffers that were added with iob_addbuf_free or iob_adds_free get freed 🫢

the important part though, bestie, listen: the I/O batch itself is not freed. nope. she survives. she's still here, still iconic, and you can just start adding transactions to it again like nothing ever happened. main character energy fr fr. πŸ‘‘


πŸ‘€ SEE ALSO πŸ‘€


no cap: if you were worried this nukes the batch itself, it does not. batch stays, transactions go. iykyk. πŸ’–

mwah πŸ’‹ that's the whole page β€” straight outta the Library Functions Manual, iob_reset(3), same as it ever was. go forth and reset, you gorgeous little syscaller. πŸŒˆπŸ¦‹