Blame SOURCES/0001-lib-files.c-Fix-an-issue-where-execution-could-not-r.patch

5b830c
From a20415d6f1d3fa09300ff1181646fe7e1785fd15 Mon Sep 17 00:00:00 2001
5b830c
From: Imran Desai <imran.desai@intel.com>
5b830c
Date: Sun, 29 Mar 2020 10:14:28 -0700
5b830c
Subject: [PATCH] lib/files.c: Fix an issue where execution could not reach
5b830c
 function return
5b830c
5b830c
Signed-off-by: Imran Desai <imran.desai@intel.com>
5b830c
---
5b830c
 lib/files.c | 8 +++-----
5b830c
 1 file changed, 3 insertions(+), 5 deletions(-)
5b830c
5b830c
diff --git a/lib/files.c b/lib/files.c
5b830c
index ef2170b079e1..501f88d11b48 100644
5b830c
--- a/lib/files.c
5b830c
+++ b/lib/files.c
5b830c
@@ -607,9 +607,7 @@ bool files_load_bytes_from_buffer_or_file_or_stdin(const char *input_buffer,
5b830c
         return true;
5b830c
     }
5b830c
 
5b830c
-//    printf("Reading file: %s\n", path);
5b830c
-//    printf("size: %u\n", *size);
5b830c
-
5b830c
+    bool retval = true;
5b830c
     /* Read from stdin */
5b830c
     if (!input_buffer && !path) {
5b830c
         UINT16 read_bytes = 0;
5b830c
@@ -640,10 +638,10 @@ bool files_load_bytes_from_buffer_or_file_or_stdin(const char *input_buffer,
5b830c
             return true;
5b830c
         }
5b830c
     } else if (path) {
5b830c
-        return files_load_bytes_from_path(path, buf, size);
5b830c
+        retval = files_load_bytes_from_path(path, buf, size);
5b830c
     }
5b830c
 
5b830c
-    return false;
5b830c
+    return retval;
5b830c
 }
5b830c
 
5b830c
 tool_rc files_save_ESYS_TR(ESYS_CONTEXT *ectx, ESYS_TR handle, const char *path) {
5b830c
-- 
5b830c
2.31.0
5b830c