TT_MESSAGE_OBJECT(3)

πŸ“¦
version 2.5.3 Β· 2 versions
, in nixos 26.05

πŸ’– tt_message_object β€” like, the whole manual page, bestie πŸ’–

okay so this is a library call page β€” the tt_message_object one β€” and honestly? it's a little icon and it does exactly one job. let's get into it ✨


🌸 NAME 🌸

tt_message_object β€” grab the object attribute off a message. that's it. that's the whole vibe. πŸŽ€


✨ SYNOPSIS ✨

#include &<Tt/tt_c.h>
char *tt_message_object(
Tt_message m);

yes bestie, that's the include line exactly as written, don't come for me, i don't make the rules πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

so tt_message_object retrieves the object attribute from the message you point it at. like reaching into the message's little purse and pulling out the object. iconic behavior, no notes. 🫢

the m argument is the opaque handle for the message involved in this operation β€” opaque meaning you don't peek inside it, you just hold it and trust it. main character energy honestly. πŸ‘‘


πŸ”₯ RETURN VALUE πŸ”₯

upon successful completion, tt_message_object returns the object involved in this message. slay.

and then β€” this is the important part, don't skip it β€” the application can use tt_ptr_error(3) to extract one of the following Tt_status values from the returned pointer:

  • TT_OK β€” the operation completed successfully. we love a clean win πŸ’–
  • TT_ERR_NOMP β€” the ttsession(1) process is not running and the ToolTalk service cannot restart it. so like... nobody's home and the door is locked 😭
  • TT_ERR_OBJID β€” the objid passed to the ToolTalk service does not reference an existing object spec. it's giving "ghost tag" πŸ’€
  • TT_ERR_POINTER β€” the pointer passed does not point to an object of the correct type for this operation. wrong vibe entirely, respectfully πŸ™ˆ

πŸŽ€ APPLICATION USAGE πŸŽ€

bestie listen to me: the application should use tt_free(3) to free any data stored in the address returned by the ToolTalk API. free your memory. release it. let it go. ✨🧚


🌈 SEE ALSO 🌈

Tt/tt_c.h - Tttt_c(5), tt_ptr_error(3), tt_free(3).


ngl the whole page is short but every single line ate, so keep it in your back pocket, iykyk πŸ’œ

okay bye bestie, this was tt_message_object from the library call manual β€” that's the source/version tag sitting right there at the bottom of the page, and yep, it's the same tt_message_object(library call) energy from top to bottom. go forth and free your pointers πŸ“πŸ¦‹πŸ’…

πŸ“¦ where this page comes from