|
|
@ -398,10 +398,12 @@ void db_close_stream(output_t *op) { |
|
|
if (stream.s) { |
|
|
if (stream.s) { |
|
|
size_t count = fread(stream.s, 1, stream.len, f); |
|
|
size_t count = fread(stream.s, 1, stream.len, f); |
|
|
if (count != stream.len) { |
|
|
if (count != stream.len) { |
|
|
|
|
|
stream.len = 0; |
|
|
ilog(LOG_ERR, "Failed to read from stream"); |
|
|
ilog(LOG_ERR, "Failed to read from stream"); |
|
|
fclose(f); |
|
|
fclose(f); |
|
|
if ((output_storage & OUTPUT_STORAGE_FILE)) |
|
|
if ((output_storage & OUTPUT_STORAGE_FILE)) |
|
|
goto file; |
|
|
goto file; |
|
|
|
|
|
free(stream.s); |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|