WAFFLE_TEARDOWN(3)
π WAFFLE_TEARDOWN(3) β the waffle manual, bestie edition β¨
okay so. welcome to the page about waffle_teardown, part of the waffle manual. section 3. let's get into it π
πΈ NAME πΈ
waffle_teardown β tear down waffle's per-process global state π§Ήβ¨
π¦ SYNOPSIS π¦
#include <waffle.h>
bool waffle_teardown(void);
π DESCRIPTION π
Feature test macro: WAFFLE_API_VERSION >= 0x0106. (go peek at waffle_feature_test_macros(7) for the deets π«Ά)
waffle_teardown() tears down the per-process global state of the waffle library. like. it's the cleanup era. the closing credits. the "okay pack it up" moment π
and listen β a call to waffle_teardown() can fail. it's not always gonna eat, and if it doesn't, the caller is advised to use waffle_error_get_info, waffle_error_get_code and/or waffle_error_to_string to retrieve the error. that's your group chat debrief, use it π±
β οΈ now the serious part, no cap: in case of an error that differs fromWAFFLE_ERROR_NOT_INITIALIZED, the caller should not use the Waffle API, because the global state is likely to be in an undetermined/corrupt state. like genuinely, do not touch it. stepped on, don't eat π in the case ofWAFFLE_ERROR_NOT_INITIALIZED, though? you should callwaffle_init()prior to reusing Waffle. simple as that π
π RETURN VALUE π
- Functions whose return type is
boolreturntrueon success andfalseon failure. - Functions whose return type is a pointer return
NULLon failure.
and bestie, use waffle_error_get_info(3) to get information about any errors. always check the receipts π§Ύβ¨
π₯ ERRORS π₯
see waffle_error(3) for the complete list of waffle's error codes. the whole menu fr fr π
WAFFLE_ERROR_NOT_INITIALIZEDβ Waffle has not been initialized with a successful call towaffle_init()since the last call towaffle_teardown()or the start of the program. basically you're trying to teardown something that was never set up. it's giving "closing a tab you never opened" π
πΈ ISSUES πΈ
please report bugs or and feature requests to https://gitlab.freedesktop.org/mesa/waffle/issues. drop the link in the chat, we'll look at it together π«Ά
β SEE ALSO β
π AUTHOR π
Emil Velikov <emil.l.velikov@gmail.com>
- Maintainer
we stan π«Άβ¨
π COPYRIGHT π
Copyright Β© 2013 Intel
This manual page is licensed under the Creative Commons Attribution-ShareAlike 3.0 United States License (CC BY-SA 3.0). To view a copy of this license, visit http://creativecommons.org.license/by-sa/3.0/us.
and that's the whole page, bestie π this one was shipped by waffle, dated 07/06/2026, living in section 3 as WAFFLE_TEARDOWN(3). slay, go forth and tear it down responsibly ππ¦β¨
π¦ where this page comes from
- ubuntu stonking: libwaffle-doc 1.8.3-1 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms