twn_util: dont add empty list
This commit is contained in:
parent
474ea84a77
commit
8e15c9ec3c
@ -233,6 +233,9 @@ String file_read(char const *file, char const *operation) {
|
|||||||
return (String){NULL, 0};
|
return (String){NULL, 0};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (list.list == NULL)
|
||||||
|
return (String){NULL, 0};
|
||||||
|
|
||||||
String s = {(char *)list.list, (float)list.length - 1};
|
String s = {(char *)list.list, (float)list.length - 1};
|
||||||
arrpush(read_files, s);
|
arrpush(read_files, s);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user