summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristopher Michael <devilhorns@comcast.net>2021-09-21 10:35:34 -0400
committerChristopher Michael <devilhorns@comcast.net>2021-09-21 10:35:34 -0400
commit3f1d183c06c78b22f4270d752e88e8dbaa89a015 (patch)
tree6ea8ff085ef7d585030d7e90e69a6727cc17ba9b /src
parent2c7b1a992c37b9919c0a32320e6eeccf659a3cf8 (diff)
downloadefl-3f1d183c06c78b22f4270d752e88e8dbaa89a015.tar.gz
eina-test: Fix unchecked return value
Coverity CID1401015 complains about an unchecked return value here, so let's check that fread actually succeeded (return > 0). Fixes CID1401015 @fix
Diffstat (limited to 'src')
-rw-r--r--src/tests/eina/eina_test_simple_xml_parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tests/eina/eina_test_simple_xml_parser.c b/src/tests/eina/eina_test_simple_xml_parser.c
index 34c8d69002..5f41d2b038 100644
--- a/src/tests/eina/eina_test_simple_xml_parser.c
+++ b/src/tests/eina/eina_test_simple_xml_parser.c
@@ -237,7 +237,7 @@ EFL_START_TEST(eina_simple_xml_parser_parse_with_custom_callback)
if (buf)
{
- if (fread(buf, 1, sz, f))
+ if (fread(buf, 1, sz, f) > 0)
{
int parse_current_state = simple_xml_parser_current_state_begin;
eina_simple_xml_parse(buf,