fCreate(3)

πŸ’– fCreate(3) πŸ’–

okay bestie, so this one lives in util/ulocks.h and it's literally just called fCreate β€” she creates a file lock. that's the whole vibe. slay ✨


🌸 SYNOPSIS 🌸

#include <util/ulocks.h>

NEOERR *fCreate(int *plock, const char *file);

πŸŽ€ ARGUMENTS πŸŽ€

  • plock β€” this is where the lock goes. like, the little spot you're reserving for it to live. 🫢
  • file β€” the path of the file you're using as the lock. yes, that file. the lock file. she's the moment. πŸ’…

πŸ¦‹ DESCRIPTION πŸ¦‹

so what she does is: creates a file lock on the named file file. and then the lock itself gets returned in plock. that's it, that's the whole thing. no cap. ✨

MT-Level: Safe. β€” so you can use her from multiple threads and she will not betray you. iconic behaviour, honestly. πŸ‘‘


πŸ’œ RETURN VALUE πŸ’œ

  • plock β€” gets set to the lock identifier. so when you look in there afterwards, boom, that's your lock id. πŸŽ€

πŸ”₯ SEE ALSO πŸ”₯

mCreate(3), fCreate(3), mUnlock(3), fUnlock(3), cBroadcast(3), cSignal(3), fFind(3), cDestroy(3), cCreate(3), mDestroy(3), cWait(3), fLock(3), fDestroy(3), mLock

like if you're into this one you're gonna wanna meet the whole friend group fr fr πŸ’–


mwah, that's a wrap bestie πŸ’– this was ClearSilver, dated 12 July 2007 β€” old money but she still ate πŸŽ€βœ¨πŸ¦‹