Skip to content

Commit 93699c4

Browse files
committed
Fix another issue with gtest and is_open missing return value check
1 parent 44354cf commit 93699c4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/components/logd-converter/gtest_dlt_logd_converter.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,9 @@ string t_load_json_file()
6767
string pattern;
6868
string json_sequence;
6969

70-
file.is_open();
70+
if(!file.is_open())
71+
return "";
72+
7173
while (!file.eof()) {
7274
getline(file, pattern);
7375
if (pattern.size() == 0) {

0 commit comments

Comments
 (0)