microsoft / windows-container-tools

Collection of tools to improve the Windows Containers experience
MIT License
236 stars 66 forks source link

[BUG] LogMonitor.exe version reads 2.0.0.LM_BUILDMINORVERSION instead of 2.0.0 #145

Closed mloskot closed 1 year ago

mloskot commented 1 year ago

There seem to be unexpected garbage included in the version number embedded in the executable:

$ (Get-Item .\LogMonitor.exe).VersionInfo | Format-List

OriginalFilename  : LogMonitor.exe
FileDescription   : Windows Container Log Monitor
ProductName       : Windows Container Log Monitor
Comments          :
CompanyName       : Microsoft
FileName          : F:\Docker\docker-images-apps\download\LogMonitor.exe
FileVersion       : 2.0.0.LM_BUILDMINORVERSION
ProductVersion    : 2.0.0.LM_BUILDMINORVERSION
IsDebug           : False
IsPatched         : False
IsPreRelease      : False
IsPrivateBuild    : False
IsSpecialBuild    : False
Language          : English (United States)
LegalCopyright    : (C) Microsoft Corporation. All rights reserved.
LegalTrademarks   :
PrivateBuild      :
SpecialBuild      :
FileVersionRaw    : 2.0.0.0
ProductVersionRaw : 2.0.0.0

which may be due to the fact the preprocessor define is seemingly required

https://github.com/microsoft/windows-container-tools/blob/30d5b9dd2c976895d144bc812817d8fc9a049f78/LogMonitor/src/LogMonitor/LogMonitor.rc#L63-L67

but actually optional and undefined

https://github.com/microsoft/windows-container-tools/blob/30d5b9dd2c976895d144bc812817d8fc9a049f78/LogMonitor/src/LogMonitor/version.h#L12-L16

CharityKathure commented 1 year ago

@mloskot Thank you for raising this. The issue has been addressed by this PR: https://github.com/microsoft/windows-container-tools/pull/146