Plugin initialization version data wrong?

Hello :slight_smile:

Sorry to bother again, but apparently I found something else wrong with the plugin code :sweat_smile:

In DVP_InitEx(), apparently the version that's passed to the plugin is wrong.

In DVPINITEXDATA struct (pInitExData), I'm receiving the numbers, in Directory Opus 12.6:

dwOpusVerMajor == 786438
dwOpusVerMinor == 0

On further inspection, I noticed that the value on dwOpusVerMajor is 0x000c0006, so I made this union:

	union DopusVersion
	{
		DWORD full;
		struct
		{
			WORD minor;
			WORD major;
		} splitver;
	};

Which extracts Directory Opus version correctly. (Yeah, I know, I was lazy doing this, instead of doing some appropriate bit shifting :stuck_out_tongue: )

I'm pretty sure there is a bug.

I added the current code to GitHub.

It's possible to see my DVP_InitEx in this link, with traps only allowing versions from 12.0 to 12.6 to run.

I hope this helps! :grin:

I don't see any bug there. You may just not be familiar with how version numbers work in Win32. Version numbers have four components, packed into two words. Opus 12.6 is really 12.6.0.0. The third digit is rarely used by us these days, while the fourth is used for beta versions. The next beta would be 12.6.0.1, for example.

Many of the plugins with source code provide example code showing how to check the Opus version. See those if the API docs don't have enough detail.

Yeah, I'm probably unfamiliar, then.
Thanks for the explanation! :slight_smile: