gnutls_check_version(3)

πŸ’– gnutls_check_version(3) πŸ’–

okay bestie, welcome to the gnutls manual, and this little page right here is gnutls_check_version(3) β€” it's giving "am I running a new enough GnuTLS or am I about to have a bad time" and honestly? iconic. πŸ¦‹


✨ NAME ✨

gnutls_check_version β€” literally an API function, that's the whole job description πŸŽ€


✨ SYNOPSIS ✨

#include <gnutls/gnutls.h>

const char * gnutls_check_version(const char * req_version);

✨ ARGUMENTS ✨

  • const char * req_version β€” the version string you wanna compare against, or NULL if you're feeling mysterious πŸ™ˆ

✨ DESCRIPTION ✨

so what it does is: it checks the GnuTLS Library version against the string you handed it. no cap, that's it. πŸ’…

and if you need a suitable req_version string to pass in? go look at GNUTLS_VERSION, she's got you covered ✨

also, quick shoutout: peep gnutls_check_version_numeric(), which does this exact same functionality but as a macro πŸ‘‘ iykyk.


✨ RETURNS ✨

here's the vibe check πŸ”₯ it makes sure the library version is at minimum the one you gave it as a string in req_version, and then it returns the actual version string of the library. πŸ’–

but if that condition is not met? it returns NULL. 😭 that's the sad path.

and if you pass NULL in as req_version? no check is done at all β€” it just returns the version string, periodt. 🫢


✨ REPORTING BUGS ✨

found a bug? don't be shy, tell the girlies at <bugs@gnutls.org> πŸ’Œ

Home page: https://www.gnutls.org 🌈


Copyright Β© 2001-2023 Free Software Foundation, Inc., and others. πŸŽ€

Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. (yes queen, share it, just keep the receipts πŸ’…)


✨ SEE ALSO ✨

the full documentation for gnutls is maintained as a Texinfo manual πŸ“š and if the /usr/share/doc/gnutls/ directory does not contain the HTML form, bestie, just go visit:

https://www.gnutls.org/manual/

okay that's the whole page, mwah πŸ’‹ this was gnutls_check_version(3) from gnutls 3.8.13, and yes that's the source and version, right there at the bottom where it belongs πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from