mirror of https://github.com/dirtbags/moth.git
pointscli check result of write
This commit is contained in:
parent
00dad4865b
commit
be2de973ce
|
@ -92,7 +92,11 @@ award_points(char *teamhash, char *category, int points)
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
write(fd, line, linelen);
|
if (-1 == write(fd, line, linelen)) {
|
||||||
|
close(fd);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
close(fd);
|
close(fd);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue