Skip to content

Commit

Permalink
Allow specifying <firmware>GUID</firmware> to check any version exists
Browse files Browse the repository at this point in the history
If the version is not specified then treat it as just 'exists'.
  • Loading branch information
hughsie committed Jul 16, 2019
1 parent 7b32e5f commit aaf0ce7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/fu-engine.c
Original file line number Diff line number Diff line change
Expand Up @@ -1096,7 +1096,8 @@ fu_engine_check_requirement_firmware (FuEngine *self, XbNode *req,

/* get the version of the other device */
version = fu_device_get_version (device2);
if (!fu_engine_require_vercmp (req, version, &error_local)) {
if (version != NULL &&
!fu_engine_require_vercmp (req, version, &error_local)) {
if (g_strcmp0 (xb_node_get_attr (req, "compare"), "ge") == 0) {
g_set_error (error,
FWUPD_ERROR,
Expand Down

0 comments on commit aaf0ce7

Please sign in to comment.