File tree Expand file tree Collapse file tree 3 files changed +21
-8
lines changed
Expand file tree Collapse file tree 3 files changed +21
-8
lines changed Original file line number Diff line number Diff line change @@ -49,6 +49,7 @@ static constexpr const char* kNodeStringName = "name";
4949static constexpr const char * kNodeStringDescription = " description" ;
5050static constexpr const char * kNodeStringVersion = " version" ;
5151static constexpr const char * kNodeStringDriverPackagingVersion = " packagingVersion" ;
52+ static constexpr const char * kNodeStringDriverPackagingDate = " packagingDate" ;
5253static constexpr const char * kNodeStringDriverSoftwareVersion = " softwareVersion" ;
5354static constexpr const char * kNodeStringOs = " os" ;
5455static constexpr const char * kNodeStringVirtualization = " virtualization" ;
Original file line number Diff line number Diff line change @@ -456,7 +456,17 @@ namespace system_info_utils
456456 driver.description = Get<std::string>(driver_node, kNodeStringDescription , " " );
457457 driver.software_version = Get<std::string>(driver_node, kNodeStringDriverSoftwareVersion , " " );
458458 driver.packaging_version = Get<std::string>(driver_node, kNodeStringDriverPackagingVersion , " " );
459- driver.is_closed_source = Get<bool >(driver_node, kNodeStringIsClosedSource , false );
459+
460+ if (DoesNodeExist (driver_node, kNodeStringDriverPackagingDate ))
461+ {
462+ driver.packaging_date = Get<std::string>(driver_node, kNodeStringDriverPackagingDate , " " );
463+ }
464+ else
465+ {
466+ driver.packaging_date = std::nullopt ;
467+ }
468+
469+ driver.is_closed_source = Get<bool >(driver_node, kNodeStringIsClosedSource , false );
460470
461471 // Parse major and minor
462472 if (!driver.packaging_version .empty ())
Original file line number Diff line number Diff line change 99#define SYSTEM_INFO_UTILS_SOURCE_SYSTEM_INFO_READER_H_
1010
1111#include < cstdint>
12+ #include < optional>
1213#include < string>
1314#include < vector>
1415
@@ -193,13 +194,14 @@ namespace system_info_utils
193194 // / @brief Structure containing the driver software info.
194195 struct DriverInfo
195196 {
196- uint32_t packaging_version_major; // /< The driver packaging major version
197- uint32_t packaging_version_minor; // /< The driver packaging minor version
198- std::string name; // /< The driver name
199- std::string description; // /< The driver description
200- std::string packaging_version; // /< The driver packaging version string.
201- std::string software_version; // /< The driver software version string. (Windows platform specific)
202- bool is_closed_source; // /< Flag if driver is PRO (closed source)
197+ uint32_t packaging_version_major; // /< The driver packaging major version
198+ uint32_t packaging_version_minor; // /< The driver packaging minor version
199+ std::string name; // /< The driver name
200+ std::string description; // /< The driver description
201+ std::string packaging_version; // /< The driver packaging version string.
202+ std::optional<std::string> packaging_date; // /< The driver packaging date. (YY/MM/DD) (optional as it may not be available).
203+ std::string software_version; // /< The driver software version string. (Windows platform specific)
204+ bool is_closed_source; // /< Flag if driver is PRO (closed source)
203205 };
204206
205207 // / @brief Structure containing fields used to identify the target system's hardware and software.
You can’t perform that action at this time.
0 commit comments