mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-25 21:00:12 +01:00
store cleanup fix
This commit is contained in:
parent
24471305bd
commit
e2a4146845
11
src/store.c
11
src/store.c
@ -61,9 +61,16 @@ int store_file(struct session_data *sdata, char *filename, int startpos, int len
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(len == 0){
|
if(len == 0){
|
||||||
if(fstat(fd, &st)) return ret;
|
if(fstat(fd, &st)){
|
||||||
|
close(fd);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
len = st.st_size;
|
len = st.st_size;
|
||||||
if(len == 0) return 1;
|
if(len == 0){
|
||||||
|
close(fd);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
gettimeofday(&tv1, &tz);
|
gettimeofday(&tv1, &tz);
|
||||||
|
Loading…
Reference in New Issue
Block a user