:dnvlist_get_string__default_value: fix a bogus string comparison test

Check actual_value vs "5", not "5" vs itself.

MFC after:	3 days
Reported by:	Coverity
CID:		1362021
Sponsored by:	Dell EMC Isilon
This commit is contained in:
Enji Cooper 2017-05-29 19:02:52 +00:00
parent b97ee15f62
commit f31a4fc86c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=319159

View file

@ -150,7 +150,7 @@ ATF_TEST_CASE_BODY(dnvlist_get_string__default_value)
ATF_REQUIRE_EQ(strcmp(dnvlist_get_string(nvl, "hthth", "fd"), "fd"), 0);
actual_value = dnvlist_get_string(nvl, "5", "5");
ATF_REQUIRE_EQ(strcmp("5", "5"), 0);
ATF_REQUIRE_EQ(strcmp(actual_value, "5"), 0);
nvlist_destroy(nvl);
}