Linux fault handling

This is a side trip into the unknown. So I got this bug that I wanted to do fault handling inside my program. I learned a lot of things and the differences between Linux/Unix POSIX and Windows. It is a much better way to handle things, but very difficult to manage for most. Here is a link from Linux Journal ( somewhat dated 2003), but it has a good framework. I had to make some changes, but I managed to get the job done.

They assume certain things about architecture that are not a given and I found a missing include, but these things are not show stoppers for a programmer. A person wouldn't be interested in the code unless they knew C and POSIX and could run gcc and understand "-fexceptions" and stack frames and library naming and many other things.

Great fun and it is rewarding in the fact that I have a new feature for antfarmgl. I always never make mistakes so it will never get used, but it is there for others who might modify code and generate exceptions.

I already knew about try/catch in C++,java,Python etal, but I wanted to look directly into the face of the sun for my own understanding of architecture.

You should be warned that a knowledge of one of the dark arts may be required to understand this and if you are not familiar with the dark side assembly ways you might want to pass on the link.

0 comments:

Contributors

Automated Intelligence

Automated Intelligence
Auftrag der unendlichen LOL katzen