GENDERS_ERRNUM(3)
π GENDERS_ERRNUM π (that's the genders_errnum(3) page bestie, from LIBGENDERS)
okay so picture this: your genders code is being a little drama queen and something goes wrong. this whole page is your emotional support squad of four functions that tell you what went wrong and why. no cap. π«Ά
β¨ NAME β¨
genders_errnum, genders_strerror, genders_errormsg, genders_perror β the genders error routines, aka the ones who tell you the tea β
πΈ SYNOPSIS πΈ
#include <genders.h>
int genders_errnum(genders_t handle);
char *genders_strerror(int errnum);
char *genders_errormsg(genders_t handle);
void genders_perror(genders_t handle, const char *msg);
like. look at them. four little icons. π
π¦ DESCRIPTION π¦
okay so let's go one by one, bestie, because each one does a different thing and you need to know which one to call.
genders_errnum()β hands you back the error code that's chilling insidehandle. that's it. that's the whole job. πgenders_strerror()β give it anerrnumand it gives you back a pointer to a string that describes that error code. so it's the translator, the one who explains what the cryptic number actually means.genders_errormsg()β same energy but you don't have to go digging: it returns a pointer to a string describing the error stored inhandle. logically it's the exact same thing as this:
char *genders_strerror(genders_errnum(genders_t handle));
like literally, that's the whole vibe. it's just doing both steps for you so you don't have to. π
genders_perror()β this one is givingperror(3)energy, fr fr. it prints a message to standard error output describing the error stored inhandle. and here's the cute detail: ifmsgis notNULL, then the string thatmsgpoints to gets printed first β followed by a colon, and then a blank β and then the error message. so you get your lil label AND the explanation. iconic.
π the classic two-step (iykyk)
generally, the way this goes is: you call genders_errnum() to grab the error code, and then you hand that code straight over to genders_strerror() to get the actual description. that's the whole workflow. periodt. β¨
π FILES π
/usr/include/genders.h
π SEE ALSO π
hmm, this page didn't list any SEE ALSO entries β but genders_perror() is similar to perror(3), so go peek at that if you want the cousin function's lore. π§
β οΈ real talk, no skips:genders_strerror()andgenders_errormsg()both hand you back a pointer to a string β they're not passing you a fresh copy, so don't go wild freeing or mutating what you get back. π
and that's the page, bestie!! this one came from LLNL, dated August 2003, and it lives under GENDERS_ERRNUM(3) β yes it's vintage, yes it still slays, we love a legacy baddie. πβ¨ππ¦πΈπ π«Ά
π¦ where this page comes from
- epel 10: libgenders-devel 1.28.1~^20231119git27b915d-5.el10_2 Β· GPL-2.0-only
- fedora 43: libgenders-devel 1.28.1~^20231119git27b915d-5.fc43 Β· GPL-2.0-only
- fedora 43: libgenders-devel 1.28.1~^20231119git27b915d-5.fc43 Β· GPL-2.0-only
- fedora 44: libgenders-devel 1.28.1~^20231119git27b915d-6.fc44 Β· GPL-2.0-only
- fedora 44: libgenders-devel 1.28.1~^20231119git27b915d-6.fc44 Β· GPL-2.0-only
- opensuse-leap 16.0: genders-devel 1.32-bp160.1.11 Β· GPL-2.0-or-later
- opensuse-leap 16.0: genders-devel 1.32-bp160.1.11 Β· GPL-2.0-or-later
- opensuse-leap 16.0: genders-devel 1.32-bp160.1.11 Β· GPL-2.0-or-later
- opensuse-leap 16.0: genders-devel 1.32-bp160.1.11 Β· GPL-2.0-or-later
- Copyright (C) 2007-2019 Lawrence Livermore National Security, LLC
- Copyright (C) 2001-2007 The Regents of the University of California
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms