Commit f0ea22a1 authored by Anel Husakovic's avatar Anel Husakovic Committed by Andrew Hutchings

MDBF-534: Coverity scan: fix client folder

```------------------------------
File: `mysqlbinlog`
```

------------------------------
- Coverity (FORWARD_NULL):
https://scan5.scan.coverity.com/reports.htm#v58936/p10357/fileInstanceId=231728438&defectInstanceId=53074517&mergedDefectId=1519690&eventId=53074517-46

`mysqlbinlog` - for `opt_raw_mode` file is set to 0, make sure it opened
before.
parent 48788911
......@@ -3169,7 +3169,7 @@ int main(int argc, char** argv)
/* Set delimiter back to semicolon */
if (retval != ERROR_STOP)
{
if (!stop_event_string.is_empty())
if (!stop_event_string.is_empty() && result_file)
fprintf(result_file, "%s", stop_event_string.ptr());
if (!opt_raw_mode && opt_flashback)
fprintf(result_file, "DELIMITER ;\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment