AuSetErrorHandler(3)
β¨ AuSetErrorHandler β¨
ok so bestie, welcome to AuSetErrorHandler(3) β it's a Library Functions Manual page, it's giving very much "let me hold your hand while your audio server has a lil oopsie" π
πΈ Name πΈ
AuSetErrorHandler β set nonfatal error handler. that's it, that's the whole job. no cap. π
π Synopsis π
#include <audio/audiolib.h>
AuBool (*AuSetErrorHandler(server, handler))()
AuServer *server;
AuBool (*handler)(AuServer *, AuErrorEvent *);
look at that function-pointer-of-a-function-pointer situation. it's giving main character energy. πβ¨
π¦ Arguments π¦
serverβ the connection to the audio server. like, which server are we talking to, bestie? πhandlerβ the non-fatal error handler you want installed. passNULLif you want to reinstall the default handler instead. yes,NULLis a valid vibe here. π«Ά
π Description π
so what AuSetErrorHandler does is: it sets the non-fatal error handler and hands you back the previous handler. two-for-one, obsessed. π₯
this error handler gets invoked whenever a non-fatal error (error event) is received. and because this condition is not assumed to be fatal, it is totally acceptable for the error handler to return. no dramatic exit required, it can just come back. π
β οΈ but lowkey important: the error handler should not call any functions (directly or indirectly) on the server that will generate protocol requests, or that will look for input events. fr fr, don't do it. it's not the moment. π«π
π See Also π
AuServerNameAuGetErrorDatabaseTextAuGetErrorTextAuSetIOErrorHandlerAuSynchronize
audiolib β Network Audio System C Language Interface
ok that's the whole page, bestie, you ate that πβ¨ this was from the audiolib error handling corner of the manual, version 1.9.4, and yep it's still the AuSetErrorHandler(3) page. go forth and handle your errors non-fatally ππ§ββοΈπ
π¦ where this page comes from
- debian bookworm: libaudio-dev 1.9.4-7
- debian trixie: libaudio-dev 1.9.4-9
- ubuntu jammy: libaudio-dev 1.9.4-7build1
- ubuntu noble: libaudio-dev 1.9.4-8
- ubuntu questing: libaudio-dev 1.9.4-9
- ubuntu resolute: libaudio-dev 1.9.4-9.2
- ubuntu stonking: libaudio-dev 1.9.4-9.2
- copyright 1994 Steven King
- Copyright 1993 Network Computing Devices, Inc
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms