Thanks for your bug report. You have bumped into backwards compatibility. As you may have noticed, the -g switch says you can load a small icon, a large icon, or the actual icon. Small means 16, large means 32, actual means... whatever the API decides to return by default. The -g switch was added a long time ago when icon handling was a lot simpler.

mIRC actually uses several icon loading APIs: LoadImage() (allows loading an icon as close as possible to specified size), ExtractIconEx() (allows requesting either a small or a large icon), and ExtractIcon() (does not allow requesting a specific size), depending on whether the previous API failed.

In short, the -g switch is an old switch. I might be able to extend it to handle a greater variety of icon sizes. However, until then, you will have to use .ico/.dll/.exe files that separate their icons more clearly to allow loading of different icon sizes.