PX_CLOSE(3)

πŸ’– PX_CLOSE πŸ’–

okay bestie, welcome to PX_close β€” it's the paradox.h era, it's giving "closes an instance of a Paradox file", and it's honestly so much simpler than it sounds. ✨


🌸 NAME 🌸

PX_close β€” closes an instance of a Paradox file. yes that's it, that's the whole job. iconic of her honestly πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

#include <paradox.h>

void PX_close(pxdoc_t *pxdoc)

πŸ¦‹ DESCRIPTION πŸ¦‹

so. PX_close closes a Paradox file. that's the vibe. 🫢

BUT β€” and this is the part where you gotta pay attention, no cap β€” do not confuse this function with PX_delete(3). they are not the same thing, they are not interchangeable, they are not sisters. PX_delete(3) has to be called after PX_close(3) to free all the resources that were used for the database. so like, close first, delete after. in that order. periodt. πŸ”₯

here's the tea on the file handle itself:

  • if the file was opened by pxlib, then PX_close(3) closes the associated file for you. she handles it. you're free. 🧚
  • but if the database file was opened with fopen(3), then it has to be closed with flcose(3) by the calling application. that's on you, bestie, not on her. πŸ™ˆ
⚠️ fr fr: opening with fopen(3) means the close is your problem, and it's flcose(3) that does it. don't come crying to PX_close(3), she already told you.

⭐ SEE ALSO ⭐

go read them, they're the rest of the friend group πŸ’œ


πŸ‘‘ AUTHOR πŸ‘‘

this manual page was written by Uwe Steinmann uwe@steinmann.cx. thank you for your service, king 🫑✨


and that's the whole page, babe πŸ’– this cutie lives in the Library Functions Manual as PX_CLOSE(3) β€” now go close your files and free your resources, in that exact order, or else. πŸ˜­πŸŒΈπŸ¦‹