excellent setjmp/longjmp tutorials
Hi I'd like to read good tutorials on setjmp/longjmp in C. It'd be better if there're examples which are real rather than artificial.
Thanks.
这不是一本真正的教程,但libpng文档描述了库如何使用setjmp / longjmp来执行错误处理。
The book "C interfaces and implementation" explains the concept well and implements a usable "exception" simulation in C using these constructs. The code for it (chapter 4) is freely available online here.
Edit: also see this SO thread
然后,您应该阅读UNIX(R)环境(第二版)中的高级编程。以下是您要查找的示例http://my.safaribooksonline.com/0201433079/ch10lev1sec15(只是预览版)
链接地址: http://www.djcxy.com/p/43584.html上一篇: HTTP.sys barfs