NNG_PIPE_CLOSE(3)

πŸ“¦
version 1.12.0 Β· 4 versions
, in ubuntu stonking

πŸ’… nng_pipe_close(3) β€” bestie's guide to closing a pipe

okay so real talk, this one lives in the NNG Reference Manual (section 3, the library-calls girlies) and it's literally the "bye bye pipe" button. short page, big energy. let's go πŸŽ€


🌸 NAME 🌸

nng_pipe_close β€” close pipe. that's it, that's the whole job. she closes the pipe. periodt.


✨ SYNOPSIS ✨

#include <nng/nng.h>

int nng_pipe_close(nng_pipe p);

πŸ¦‹ DESCRIPTION πŸ¦‹

so the nng_pipe_close() function closes the pipe you hand it, p. like, you pass her the pipe and she's done, no take-backsies, the vibe check has concluded. πŸ™ˆ

now here's the tea β€” messages that have already been submitted for sending may be flushed or delivered, and that depends on the transport. so no cap, it's giving "maybe she'll finish her sentence, maybe she won't." it's not a promise, bestie, it's a maybe. πŸ’€

once this call returns, any further attempts to use that pipe will result in NNG_ECLOSED. you can't come back to the group chat after you left the group chat. 😭

Tip πŸ’– Pipes are automatically closed when their creator closes, or when the remote peer closes the underlying connection. so like, sometimes the breakup happens without you pressing the button. the universe handles it. πŸ‘‘

🌈 RETURN VALUES 🌈

  • she returns 0 on success πŸ’…
  • and non-zero otherwise. anything that isn't a zero is a whole situation, iykyk.

πŸ”₯ ERRORS πŸ”₯

  • NNG_ECLOSED β€” the pipe p is already closed or was never opened. so either you already said goodbye, or you two were never a thing in the first place. awkward! πŸ’€

πŸ‘‘ SEE ALSO πŸ‘‘


and that's the whole page, babe. this one's straight out of the NNG Reference Manual, dated 2026-06-30 β€” go close some pipes, stay hydrated, and remember: she's closed, don't text her. 🫢✨🌸

πŸ“¦ where this page comes from