How to know current version of madCodeHook

c++ / delphi package - dll injection and api hooking
Post Reply
nomen
Posts: 48
Joined: Wed Jun 25, 2008 7:15 am

How to know current version of madCodeHook

Post by nomen »

Hi:

I suppose this is a very simple question, but I can´t find the answer.
Is there any way of knowing, through the api or some define, the current version of madCodeHook?

Thank you very much.
madshi
Site Admin
Posts: 10753
Joined: Sun Mar 21, 2004 5:25 pm

Re: How to know current version of madCodeHook

Post by madshi »

In the madCodeHook installation folder, open "Help\Content.htm", then click on "Version History".
nomen
Posts: 48
Joined: Wed Jun 25, 2008 7:15 am

Re: How to know current version of madCodeHook

Post by nomen »

Hi Madshi:
Sorry, maybe I badly explained.
I need to know the current version programmatically.
Something like

GetMadCHookVersion(char *version)
printf ("Current version is: %s \n",version);

Is to know which version is being used in my different binaries.

Thank you for your fast anser.
madshi
Site Admin
Posts: 10753
Joined: Sun Mar 21, 2004 5:25 pm

Re: How to know current version of madCodeHook

Post by madshi »

That is currently not supported, unfortunately.
nomen
Posts: 48
Joined: Wed Jun 25, 2008 7:15 am

Re: How to know current version of madCodeHook

Post by nomen »

Wow, that's a shame. You intend to support it?
madshi
Site Admin
Posts: 10753
Joined: Sun Mar 21, 2004 5:25 pm

Re: How to know current version of madCodeHook

Post by madshi »

What purpose do you need this for? You're the first customer asking for this!
nomen
Posts: 48
Joined: Wed Jun 25, 2008 7:15 am

Re: How to know current version of madCodeHook

Post by nomen »

Suppose I have multiple versions of an application with different versions of MadCodeHook.
One of the users of the application describes me some error that indicates a communication problem IPC in Windows 8.

I get, among other lots, the version information of MadCodeHook and realize that is the 3.1.3
In Version History of MadCodeHook find that, in version 3.1.4, fixes a bug on "IPC in Metro apps only worked without reply".
Upgrade the application with version 3.1.4 of MadCodeHook and the user tells me everything is fine now ;-)

Of course, this is just a guess, but I think it might be useful to me.
madshi
Site Admin
Posts: 10753
Joined: Sun Mar 21, 2004 5:25 pm

Re: How to know current version of madCodeHook

Post by madshi »

Well, don't you keep a record of all sources and third party components that are part of your software release versions? If your customer tells you he has a problem which seems to be related to an IPC problem in win8 with your software version XYZ, then you should be able to find out which version of which third party libraries you were using to build your software version XYZ. Of all the third party software I'm using, only few are offering a "GetVersion()" function, so I simply store the full 3rd party software which each released version. This way I can not only find out which 3rd party version I was using, but I can even create a minor bugfix for a very old version of an application.

I could add some sort of GetVersion() API to my to do list, but I'm not sure I like the idea, because it would mean that I'd have to remember increasing that version number every time a release a new build, in addition to all the other version information elsewhere. It's easy to forget things like that, if they're not fully automated. And automating that isn't so easy...
nomen
Posts: 48
Joined: Wed Jun 25, 2008 7:15 am

Re: How to know current version of madCodeHook

Post by nomen »

Hi Madshi:
Relax, do not worry.
I added at the beginning of madCHook.h the following define (I simply copied the value of the information you put in the second line of the file):

Code: Select all

     # define MADCHOOK_VERSION "3.0.2"
If I forget to add in the next version, the compiler will issue an error.
This is enough for me.

Thank you very much!
madshi
Site Admin
Posts: 10753
Joined: Sun Mar 21, 2004 5:25 pm

Re: How to know current version of madCodeHook

Post by madshi »

The header version only changes when I change the header, not when I change the library itself. So you want to use the version number of the library, which you can extract from the help/documentation (see my first post), or from the installer.
Post Reply