Learning experience - About SEH (1)

zhaozj2021-02-12  143

About SEH (1) For a long time, I wanted to write something, and I was too lazy. It's hard to write a process inserted, and I was returned, depressed. Get a game every day, play miracles, in fact, I know that I have to study hard every day, I can't help. Question.

Everyone is clear, it is not written here, which is a structured error handling, I don't know if I have any translator.

In fact, I have never been concerned about this in the past. Is it try, caratch, what is difficult, these days have also seen something, I think this is not so simple.

Clearing the purpose of learning, the purpose of SEH here is to do some "unfair" things, such as hackers, enter Ring0 Asia, etc., I will involve many other knowledge, I know that I will try to explain the white, However, if you think that VB is already very easy to use people who don't want to learn other languages, I advise you still don't look, there is nothing you want, most of them are compilation. Not my dissatisfaction, but this is a fact. Maybe you can use VB to compile the compilation, but that is just a strange skill.

First, let's take a method of processing about the errors in C .

This is a very simple statement. Generally speaking, and Catch is used for use, for example:

Try {int a = 34; INT B = 0 int C = a / b;} Catch (int errno) {....... // error handling} program executes the statement in the TRY block, if you encounter an error If the error type is compared to the error type of the error type and the back CATCH brackets, if there is a match to hand it to this CATCH process, if there is no system processing, the default method is interrupted.

The most important thing here is the wrong type, I don't have much here, you go to book, we will mainly come into contact with ASM, after all, more free, this is just a topic.

Of course, there is a simple method, no matter what is wrong, you can use the Catch allocation, you can use the following code:

Catch (...) {........... // Processing code}

Use caratch (...) to capture any type of exception.

This is the exception handling of C packages. In fact, it is similar to the general SEH, first writing here, it seems to be more than our goal ---- entering Ring0 is far more far. But don't worry, I know that there are too many you look at this too. It is so comfortable to look at this time. Everyone will experience our formal trip next time.

I don't know if you feel that I have to look at the old written book. They write the book to turn the corners. It is not a sentence to be clear, especially the lipman, can't stand him, but his book has to look, if Everyone has any opinions to my writing method tells me.

转载请注明原文地址:https://www.9cbs.com/read-6303.html

New Post(0)