[gnutls-devel] GnuTLS | global: define entry point of libgnutls when called as executable (4e8b9a35)

Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Tue Jan 11 16:57:36 CET 2022




Florian Weimer started a new discussion on lib/global.c: https://gitlab.com/gnutls/gnutls/-/commit/4e8b9a35efaa45859f399d4cebb1950b4e47ea4a#note_807211124

> +static const char banner_footer[] =
> +	"\nPlease send bug reports to: " PACKAGE_BUGREPORT "\n";
> +
> +const char interpreter[] __attribute__ ((section (".interp"))) =
> +	RUNTIME_LINKER;
> +
> +_GL_NORETURN_FUNC extern void __libgnutls_main (void);
> +void
> +__libgnutls_main (void)
> +{
> +	const gnutls_library_config_st *p;
> +
> +	write(STDOUT_FILENO, banner_header, sizeof(banner_header)-1);
> +
> +#define MSG "Library configuration:\n"
> +	write(STDOUT_FILENO, MSG, sizeof(MSG)-1);

You could introduce a helper function that combines `write` and `strlen`.

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/commit/4e8b9a35efaa45859f399d4cebb1950b4e47ea4a#note_807211124
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20220111/084fbf12/attachment-0001.html>


More information about the Gnutls-devel mailing list