A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Do not ignore fread results to keep ubuntu compiler happy
[simgrid.git]
/
src
/
xbt
/
xbt_str.c
diff --git
a/src/xbt/xbt_str.c
b/src/xbt/xbt_str.c
index
a3add85
..
fc0b7ff
100644
(file)
--- a/
src/xbt/xbt_str.c
+++ b/
src/xbt/xbt_str.c
@@
-709,8
+709,8
@@
char* xbt_str_from_file(FILE *file) {
memset(bread,0,1024);
while (!feof(file)) {
- fread(bread, 1, 1023, file);
- bread[
1023
] = '\0';
+
int got =
fread(bread, 1, 1023, file);
+ bread[
got
] = '\0';
xbt_strbuff_append(buff,bread);
}